How to change Netbeans cache directory? - netbeans

Is there any way to change Netbeans (7.0.1) cache directory?
I'm just wonna change directories of cache/temp for few apps... and one of them is NetBeans...

It seems this is not possible for Netbeans 7 (unless you relocate the whole userdir or create links as suggested by #MadWizard).
Fortunately, it seems this will be possible in Netbeans 7.1 by using the new --cachedir command-line option: http://wiki.netbeans.org/FaqAlternateUserdir

Quoting http://platform.netbeans.org/articles/installation.html
It is not reasonable to share this directory between different Products - the cache would be useless, the logs would get confusing and also the user modifications to the config would could be ambiguous. That is why each Product shall define its own directory prefix (based on its name) and pass it into the general nbexec command (for example using the --defaultuserdir parameter). The user can override the default during invocation of the the product launcher (e.g. nbweb --userdir myuserdir).
Review documentation pointed by me. If it does not help, you may consider using links, ie. create cache dir where desired and then within netbeans directory structure (described by the page) create link pointing to prepared cache.

Related

Is there a way to get the system configuration files folder within a Perl script?

Tried searching for this a number of ways and have not yet found an answer ...
Background
I am working on a legacy Perl application that has a lot of hard-coded values in it which should be configurable depending on where the app is installed. So, obviously, I am looking to externalize these values into a configuration file that may be located in one of a few "expected" locations. That is, using a traditional approach of checking for the configuration file in:
the current working directory,
the user's home directory (or a sub-folder therein), and
the system configuration directory (or a sub-folder therein)
where the first one found wins.
Where I am at
Perused the CPAN site a bit and found the Config::Any package, which looks promising. I can give it a list of files to use:
use Config::Any;
my $config = Config::Any->load_files(
{
files => [qw(sample.conf /home/william/.config/sample.conf /etc/sample.conf)],
use_ext => 0,
});
This will check for the existence of each of these files, and, if found, load the contents into an array reference of hash references. Not bad, but I still have to hard-code the locations where I search for my sample.conf file. Here, I assume that I am working on a Linux system, and that the location for the configuration file for all users of the application is /etc/. I could always add /usr/local/etc/ as well, but regardless, this is not system agnostic.
I can locate the user home folder using File::HomeDir for searching there, and it works correctly regardless of the system on which the application is running. So is there a similar package that would provide the /etc/ folder (or its equivalent on other platforms)?
Questions
Is there a way to do this without having to know what particular OS I am on? (Perl package or code snippet)
What is the "Perl best practice" way of accomplishing this? I cannot imagine that no one else has run into this previously.
Unless you don't plan to run your code on non unix-based hosts, according to the conventional directory layout and filesystem hierarchy standard, you may rely on a quite large set of well known places.
Anyway, nothing prevents you to dynamically build the file search specification to take account of platform oddities and their specific ways to get them (eg. File::HomeDir::Win32 vs File::HomeDir).

XPages: add a ResourceBundle Editor to the Domino Designer/Eclipse

I found this properties editor that seems perfect, I have a lot of translations to maintain. I found this editor that seems to be able to handle all languages at the same time, which is perfect for me: https://github.com/essiembre/eclipse-rbe
I managed to install the plugin, but now I have to confess that I'm way out of my league. Stumbling around in the dark...
How to start it, how to use it?
Or is there a better way to maintain properties in multiple languages?
I also have to maintain an application with a multi language user interface.
First of all I also started the attempt to use eclipse plugins for editing Java resource bundles but I am also failed... :(
After some test's with different editors I decided to work with JLokalize.
My way of proceeding:
Step (Switch to the package explorer of your Domino Designer)
Step (Select a folder for export to file system, e.g. Custom Controls or XPages)
Step (Set filter types to *.properties)
Step (Finish the export to your filesystem (or a network file share, if someone else should do the translation work))
Open and edit the resource files with JLokalize
After finishing your translation work you could import the translated files (e.g. *_en.properties for files translated to english) in your application.

Open SSO Fedlet for .Net Change Home Folder

I have an ASP.Net application which uses Fedlet from Oracle. It's all working but I want to move the configuration from the App_Data folder to App_Data\Fedlet since we have all our configurations and extensions sitting in the App_Data (in neatly organised subfolders).
I've checked the Fedlet.dll.config file, but can't find any way to maybe reconfigure the folder but if there's any place to change it, I'm going to guess that's the place to change it.
Any pointers would be much appreciate as I've been searching for hours
Since I haven't found any answers anywhere on the net regarding this and since I managed to guess my way through, I decided to post the answer here for future reference both for myself and others.
If you place your web pages into a subfolder (example /pages/) then just place an app_data folder into the new folder (example /pages/app_data/) an

Change folder names in Joomla site

I'm trying to change some folder names in a Joomla (1.5.23) website to better define what they contain. Everything I find refers to changing template names but in the admin panel I don't see anything named "templates".
So far I've been able to make all my changes by directly editing the files in the database but I can't find how to change a folder name. I tried changing it in the category manager and published it but still uses the old folder names.
Any direction would help at this point.
From the Admin, under Extensions, you'll see Template Manager. It displays your available templates based on folders in the \templates folder, and uses the templateDetails.xml within that folder for the admnin form.
Your best bet is to simply copy one of those folders, makes changes in the templateDetails.xml files (so you that you'll see a different name in the admin), and further investigate how it works from the copied version.

NetBeans: should nbactions.xml, nb-configuration.xml and catalog.xml go into source control?

This thread is very useful for finding out which files in Netbeans should go into source countrol, but it doesn't cover all files.
In particular I'm wondering whether the following files should go into source control. Here are my assumptions/guesses:
nb-configuration.xml - easiest - the file itself in the comment says it should go into source control.
nbactions.xml - from what I see this file stores information typical to running the application. I.e. JVM arguments etc. So I suppose it is a question of taste - if you want other developers to have a "suggested" Run configuration - include it. Otherwise - don't. Correct?
catalog.xml - not sure what this does (I GUESS it's used by the editor to find out xml schemas and such to enable syntax coloring, but it's just a guess). Anyway - I see that this file has system-specific information (path) - so it shouldn't go into source control.
Can anyone confirm the above?
Thanks,
Piotr
I never put my IDE configuration files in the repository, for several reasons:
other colleagues may want to use theirs;
other colleagues may want to use other IDEs (such as Eclipse) and seeing those files (or even have to exclude them from the checkout) could be annoying for them;
some of these files are generally not related to a single project, others automatically generated, so no need to store them in the source code of every project.
In order to exclude them, our first solution was the .svnignore, but it was still logically wrong to modify some shared content for the specific needs of a single user, so we decided to be more strict:
in my ~/.subversion/config I have:
[miscellany]
global-ignores = nbactions.xml nbproject
Hope this helps,
Marcello
In my Maven based projects I put nbactions.xml into source control. Just make sure to change absolute paths to relative ones.
I put nbactions.xml into source control BUT there is a caveat: it's internal format can change so if your developers, for any reason, use different versions of NetBeans you could have to remove it because sharing it becomes nasty.
Recently I upgraded from NetBeans 7.3.1 to 7.4 and the "Run" action was giving a strange error message. I solved the problem by deleting and regenerating nbactions.xml: the old one had a custom Maven goal for the "Run" and "Debug" actions; it was org.codehaus.mevenide:netbeans-deploy-plugin:1.2.4:deploy it was not visible in the IDE v7.3.1 (perhaps it has been generated by an even older version for internal usage) and was generating a class not found for org.openide.util.Lookup in v7.4. I'm documenting the problem here because I found the solution by myself after an unsuccessful search on the Net. I hope this can help someone else.