Adding an external project directory in phpStorm 6.0 to keeping workspace files separated from code? - phpstorm

I am try to keep separate workspace directory and code directories in my php project and sweating to understand/find how this could be achieved. A couple of revisions back I tried phpStorm and found that it does not provide such feature.
I just want to know if phpstorm 6.0 has this feature or still lacking it ? If possible please help me out.
Work Around
File > Settings >[Directories]
+[Add Content Root] to add external directory
Assuming that you have created project separate from code.Some of the tool might not work
as expected

This works for linux using sshfs, sorry for windows users.
I've created this folder structure in my pc
/mnt/remote_code/code/
And i have to mount code from server like this
sshfs user#server:/var/www/server_code/ /mnt/remote_code/code/
Code from server will be mounted in code folder
In PS I open this directory: /mnt/remote_code/
So, that means PS will create this folder /mnt/remote_code/.idea (indexing and saving all project and ide settings), and keeps the code folder (with remote code inside) without changes.
Hope it help you.
Greetings.

Related

How do I modify the defaul graphdb.home directory?

I have installed GraphDB Free v9.3 in LinuxMint 19.3.
The workbench is running fine though I haven't created any repositories yet. This is because I have noticed that although the application is installed at /opt/graphdb-free, the data, conf and log files are in a hidden folder below my home folder: /home/ianpiper/.graphdb/conf (etc).
I would prefer to store these folders on a separate volume, mounted at /mnt/bigdata. In the documentation it suggests that I can set graphdb.home using the graphdb.properties file (though I don't seem to have such a file in my installation) or in the startup script. I think this script might be /opt/graphdb-free/app/bin/setvars.in.sh, and that I could use this to change
-Dgraphdb.home=""
to
-Dgraphdb.home="/mnt/bigdata"
Could a knowledgeable person advise as to whether my understanding is correct, and if so what the best way is to change the location of graphdb.home?
Thanks,
Ian.

How to make PhpStorm access a proper directory?

I'm running Linux Mint. My existing projects are located at the /var/www/* folders. But when I'm trying to create a new project then the PhpStorm's file browser is not showing me that folder at all. Like there is just no /var/www folder, but I know it is there and is having a full access permissions (0777).
In addition it shows for example a folder /var/data/JetBrains which is not actually available in my system (terminal: cd /var/data - no such file or directory).
So it seems like it is showing some kind of its own /var folder (virtualized?), not the one that is actually in my system. How can I solve this problem, how can I make it so it use my system's /var folder?
Solved. Do not install the PhpStorm from the Mint's software manager. It comes there in some kind of wrapper that isolates the filesystem.

Publishing NopCommerce

I have my site up and running, but because of number of changes, i decided to publish an updated version. Before doing so i have made backup of my files and databases on the host, just in case.
Now this is what i did: Publish Nop.Web used FTP, configuration is set to release and from file publish options checked Delete all existing files prior to publish, as i was publishing to the same folder wwwroot. After publish was completed NopCommerce installation appeared (btw i would like to use the same db i used before) even tho settings.txt from the project I was publishing had the correct string path. I tried 2-3 times to pass the installation with no success (error: One or more sequence... something like that), checked settings.txt on the host and it was empty (no idea why), but i just edited it with the string path.
Now installation is gone i have my site running again with all the products and user information (i assume that means string path to db is good), but my theme is reseted to default, like all my changes to it (footer links, background, logo, favicon..etc etc) only thing that stayed as it should was the nivo slider widget that has the correct pictures displaying on this 'reseted' theme.
Checked General settings for theme settings if its the correct theme selected.
Also i have noticed this, i assume with those 2-3 unsuccesful install tried i have made some changes in db
http://i.imgur.com/wfXQYj6.png
Any suggestions how to sort this whole thing, before publishing i was running my site locally and it was good, i have backups of db and files(ones that i used before this publish)
I am using Nop version 3.4 and arvixe hosting. Sorry for my long post but i wanted to describe my steps and error as detailed as possible.
Thanks for reading and looking forward for your suggestions about this.
I haven't tried publishing features of NopCommerce version > 3.10, but you can try a more "manual" approach to make sure that files are properly updated on the server.
In short, you get files from your local machine which are needed for the built website and you upload them to your website folder on the server. You can make a backup and empty the server website folder first.
I presented that approach in this answer:
How to deploy nopCommerce 3.5 to new server from source?
You can check this batch script to see which files need to be sent to the server. The script also includes some suggestions about what else you may need to do to update the website on the server: https://gist.github.com/dan-mirescu/c14cc72e3f8ecca988b7
For Publishing the NopCommerce Application website below is the step:
Step : 1 - Publish the Nop.Web project.
Step : 2 - Publish the Nop.Admin project.
Go to the publish folder where your publish created
Step : 3 - Cut all dll from the Administration and Paste all dll to bin folder which in main bin folder for whole project
Step : 4 - Copy two things from your source project and in App_Data folder Settings.txt and InstalledPlugins.txt which is not published in your publish file so paste this two files in your publish folder in App_Data. (You need to change the connection string in Setting.txt as per your database host).
Step : 5 - Now you need to copy whole plugins folder from your source folder (but remember this plugins folder you need to copy from the Presentation folder not from the main source where the solution file are there.).
Step : 6 - Now your publish have been ready.(now you can deploy on hosting server)

How can I stop "jekyll build" from overwriting existing files in the output directory?

The source for my Jekyll-powered website lives in a git repo, but the website also needs to have a couple large static files that are too large to go under version control. Thus, they are not part of the Jekyll build pipeline.
I would like for these to simply live in an assets directory in the Jekyll destination (which is a server directory; note that I don't have have any control over the server here; all I can do is dump static files into a designated directory) that does not exist in the git repo. But, running jekyll build deletes everything in the output directory.
Is there a way to change Jekyll's behavior in this case? Or is there some other good way to handle this issue?
Not sure this addresses the specific case in the OP, but seeing as how I kept getting to this page when I finally found an answer here, I thought I'd add an answer to this question in case it helps others.
I have a git post-hook that builds my jekyll site in my webhost when I push to my host, but it was also deleting anything else that I had FTP'ed over. So now I've put anything I need to stick around in a directory (external/ in my case), and added the following to my _config.yml:
exclude: [external]
keep_files: [external]
and now files in external/ survive.
If you upload Jekyll's output directory via FTP to your server, you can use a FTP tool that lets you ignore folders.
For example, my own site is built with Jekyll, but hosted on my own webspace, so I'm uploading it via FTP.
I explained in this answer how I scripted the building and uploading process, so I can update my site with a single click.
In my case (Windows), I used WinSCP, a free command-line FTP client, for this.
If you're not on Windows, you need to use something else, but there are probably other FTP tools out there that are able to ignore folders.
To ignore your assets folder in WinSCP, you just need to put this line into the script file:
(the file which contains the actual WinSCP commands - read my other answer for more information)
option exclude "assets/"
Now you can upload your large assets folder on the server once, and it won't be overwritten/deleted when you later update your site via FTP.

How can I create a new theme for Mercurial or HgWeb?

I have a couple of Mercurial installations running on IIS7 on a 2008 server. I'd like to use the monoblue theme style for both of them, but I want to change the colour of the second one.
To accomplish this, I copied the monoblue theme, and it’s related static files and renamed it to monored. I adjusted the header.tmpl file to point at the new style-monored.css file in the static folder and updated the site's hgweb.config to reference my new theme, monored. I’ve done this in both the files in the site itself (in the template folder) and also in the Mercurial installation folder, C:\Program Files (x86)\Mercurial.
However, when I update the hgweb.config file, all that happens is that the theme reverts to paper (the default). I’m obviously missing something, but I can’t find any information on the web that points to what I’m missing out. Effectively, bar the change to the header.tmpl to reference the style-monored.css file in the static directory, the only other change I’ve made is to change the monoblue colour in the css file to a red variation i.e. #006699 became #996600.
Anyone out there got any ideas on what I’m missing out on changing. I’ve also investigated my Python installation to see if there were any Mercurial references in it, but I couldn’t find any.
FYI: My Python installation is from the Windows (x86) specific Python-2.7.5.msi
My Mercurial installation is from the Windows (x86) specific Mercurial 2.6.2 MSI installer.
In my travels about the Googlesphere, I’ve discovered the following two websites that have "instructions" on how to adjust/edit Mercurial templates. I’ve followed these, but to no avail.
http://www.endswithsaurus.com/2010/05/setting-up-and-configuring-mercurial-in_3404.html
http://colas.nahaboo.net/Hacks/HgwebMercurialTemplateCustomization
Any help would be greatly appreciated.
Thanks.
UPDATE: I found the answer to my question. All the template files I was making changes to are ignored by Mercurial. The correct template files to copy and edit are to be found in the \Python27\Lib\site-packages\mercurial\templates directory. I chanced upon this when I was re-reading my installation documentation on an unrelated matter.
The answer to this question is that the template files that Mercurial references to modify the display are to be found in the \Python27\Lib\site-packages\mercurial\templates directory. I discovered this when I re-visited the documentation I'd created as I installed Mercurial onto my Windows 2008 R2 server.