Force PhpStorm to recognize a project file - intellij-idea

I have an annoying scenario in PhpStorm;
When I open a file by invoking the PhpStorm launcher with a relative file path as the only argument (phpstorm src/ZumbaController.php) the application will launch, but as the file is saved a prompt appears;
open a file from the terminal
dreaded confirm write-file dialog
Opening the file by the full, absolute path does not help. Having the current working directory of the shell be the real path of the project does not help either (opening from the real project directory). Is there a way to instruct PhpStorm that this file belongs to the currently-open project?
(I considered posting on superuser, but this is more of a programers-only problem)

Related

open a directory with intellij without creating a project

I want to be able to open a directory with intellij without creating a project.
how to do it?
every time I open a folder, a project is automatically created with an .idea folder
When you use the Intellij IDE to open a directory,
It assumes that you are going to open a project (as it is the main reason to use IDEs). By default all of jetbrains's IDEs put the project specific settings for project in the .idea folder.
It is also safe to delete it if you are just opened a directory. There would be no problem in deleting this.
You can also use Terminal tab to change or open a directory (Alt+F12)
and use terminal commands to traverse between directories without creating any .idea folder.

Where does intellij idea save the local storage and preferences of libgdx (pc)

I started working with files, a simple operation of writing and reading files.
But i had an error when writing a file and now i have to fix it by hand.
Thats the problem, i don't know where is my file.
Also i would like to see the file i'm writing.
I am working with intellij idea 2016 1.4, maybe the file is complied in a jar?
Yes, i know that clearing cache its an option.
nothing here: https://github.com/libgdx/libgdx/wiki/File-handling
on the wiki link only talk about where you can find the ablolute path file but thats not my case. I get the file this way:
this.resolver = Gdx.files.local(path + "item"+ String.valueOf(weaponNumber) + ".txt");
String description = this.resolver.readString();
So.. where is the file? thanks
In the desktop version it saves the file in the assets folder inside your android module.
FileHandle file = Gdx.files.local("myfile.txt");
file.writeString("Test libGDX", false);
System.out.println(Gdx.files.getLocalStoragePath());
Output: D:\Dropbox\Projetos\Outros\gdxTest\android\assets\
The project folder in my computer is gdxTest.
In your case you have the path var so probably will be a folder inside assets folder.
But when you pack the desktop game into a jar file, the file will be created in the same folder where your game jar file is located. Usually yourProject\desktop\build\libs.
The difference is because when we configure the desktop project we set the Working Directory in the yourProject\android\assets\ folder. So to Android Studio it is the local folder of your project.

IntelliJ open project, default path

Is there a way to set a default path when opening a project?
(File -> Open) . It's always pointing out to X:\Users\\Username.
I've been googling and looking inside X:\Users\Username\.IdeaIC15\config\options for configuration file which could be the case, but found nothing so far. Anyone know where i can change it?
I searched for a solution, but there is no easy one in IDEA/Webstorm UI.
You have to edit the webstorm64.vmoptions/ idea64.vmoptions file (or webstorm.vmoptions/ idea.vmoptions if you are on a 32bit system).
Add the line
-Duser.home=YOUR_NEW_DEFAULT_PATH
The IDE settings folder (e.g. .WebStorm11) must be either copied to your new path or imported on first start of IntelliJ/WebStorm.

Xcode 'clang failed with exit code 1' error when building for test

I'm trying to build my project for test but I'm getting this error:
http://i.stack.imgur.com/K5eT5.png
I have read through all threads that I've found but nothing has helped. I have tried specifying the direct path to both the .pch and .plist files under 'build settings'.
This most likely comes up because I've duplicated my project and renamed it.
This line tells you the problem:
Check your build settings for the ".pch" file. The setting must match the actual file and path.
Try opening the file in the finder, open a new finder window, shiftcommandG and enter the file address from the build settings, you should be able to open it. Or use Terminal (you will have to quote the path in Terminal).
Beware of the spaces in the file names. I avoid spaces in file and directory names in development because they many times need to be handled in a special manner such as quoting.

no response when execute .sh file by double click on fedora20

Today,I installed fedora20 on my computer and then downloaded the Intellij idea13, but when I execute the file by double clicking, there is no response. But it works well in a terminal with ./idea.sh.
Thanks, I need your help!
I'm not a fedora user but the following may help you to understand the problem.
When you double-click an item from the file manager, the default application for that type of file is loaded.
That depends on the configuration for the specific MIME type (which is application/x-sh).
There's a big chance that the default application for .sh files is set to gedit or kwrite depending on the desktop environment. The Intellij Idea installer is binary file and maybe the application is failing to load.
Have you tried right-clicking the file and select the option 'Open in Terminal'? The context menu may also show something like Execute or Launch.