I'm using PhpStorm to develop a project.
I have created a Caddyfile to configure my caddy server.
But PhpStorm doesn't format or highlight the code of the Caddyfile.
I know that I can change the File Type for specific file but I don't know which File Type I should choose for Caddyfile.
What is Caddyfile File type in intellij idea?
Related
How can I force IntelliJ, when working on a remote project, to use the specified format specified in an XML file?
I noticed that no matter what settings I put, the formatter in IntelliJ will not honor my settings and will instead use the default formatter.
I have tried going on the remote host and changing the settings, change the settings in the cache, and changing the settings on my guest machine. Nothing seems to stick.
When I am connected to remote via IntelliJ, I can go to preferences and confirm that my desired format settings for Java are set. However, when I format, again, the default formatter is used.
What ended up working was creating the project on my local machine. This creates a .ijwb and related bazel project files.
I then moved this .ijwb folder to my remote machine. This fixed the issue and used the correct bazel options and formatter options.
I am having a quirky intellij problem.
I have a folder with a bunch of json files. When I add a specific json with name
LocalValueCode.json . InteliJ changes the file type to .file .
This only happens with this file specific filename. In file associations settings I have *.json as a pattern for my json files.
Has anyone encountered this issue before?
You need to go to Settings | Editor | File Types and make sure that this name is not associated with any incorrect file type.
I had a similar problem with a YAML file. I created the file but accidentially made it a text-type file. Then when creating YAML content in that file there was no syntax highlighting. Additionally, a bar was shown on the upper edge of the editor window stating that there are plugins for the file extension *.yml -- of which I had already one installed that worked perfectly with other YAML files.
A grep on the $HOME/.IdeaIC2018.3 directory with that filename found the .IdeaIC2018.3/config/options/filetypes.xml file that contained the following line:
<mapping pattern="cassandra-docker.yml" type="PLAIN_TEXT" />
After removing that line and restarting IntelliJ the YAML file was correctly recognized as YAML.
I just had this problem and I have an better answer, I'm leaving here for whomever might have the same issue.
If you go to Preferences > File types > Recognized file types (Text) > Registered patterns, you will find the file there registered as an association. Just remove the association and you should be fine.
I need to upload currently edited JSPs to server - via scp. I have pscp on my path on my windows machine.
How do I setup inteliij idea to do this with one click for currently opened file?
(I would be able to set this up in eclipse - via 'run tool' and parameter placeholders)
In IntelliJ IDEA this feature is called External Tools. There are various variables that you can pass to the process, including the current file name.
We are using IntelliJ IDEA 10.5. How can we ensure that everyone is using the same code style and Rearranger configuration? What files should be put under version control?
You should share most of the files in .idea directory when using the directory based format, check the FAQ.
In the Code style settings make the current scheme project specific, it will be stored in .idea/codeStyleSettings.xml (or project .ipr file when using the legacy format).
Rearranger is a third-party plug-in and as far as I know doesn't store its configuration inside the project. It has options to import configuration from a file and export it to a file which you can use to maintain the same configuration by putting this file in the version control.
Note that IDEA 12 will bundle a new Rearranger plug-in which will have better configuration management (similar to the code style settings, or a part of it).
and sorry in advance I'm a newbie in HTTP server.
I'd like to customize an error 500 from an Oracle HTTP Server (OHS, built on Apache). I guess this should be done from the ErrorDocument directive, but I never found any example where this is used to customize Webspace error, only Filesystem one (under Directory or File directives).
To be more precise, here is a part of the default config used:
RedirectMatch 301 ^/analytics$ /analytics/
## Context roots for BI EE
<Location /analytics >
SetHandler weblogic-handler
WebLogicCluster miaibv194.mia.michelin.com:9704
</Location>
If I understand well, the RedirectMatch and Location directives are used to pass URLs like /analytics to Weblogic. Is it possible to add an ErrorDocument under the Location to customize errors 500 that occur for URLs like /analytics ?
I tried naively but could not make it work. Thanks !
Well, what I was originally trying to achieve was to customize HTTP errors 500 in OBIEE 11g (which uses WebLogic, and an OHS in our case). I opened a SR to try to achieve that with OHS, but it failed (Oracle guy told me I had to do it at application level), so I opened a new one to do it with WebLogic itself and here is what it gives:
• Locate the analytics.ear in your Oracle BI Home directory. This will be /Oracle_BI1 (or whatever you chose to name your Oracle BI Home on install)/bifoundation/analytics.ear.
So in our example scenario, this would be located at:
C:\OBI\Oracle_BI1\bifoundation\jee\analytics.ear
• Make a backup copy of the ear file so that you have a restore point to refer back to (and revert to) if needed
Note that we do not support updating the analytics.ear file, you must stop, remove the previous analytics.ear file before deploying the new one.
• Unpack the analytics.ear file to a temporary location, using the Java jar tool. Use the command line options xvf to extract the contents
to the current working directory (e.g. C:\OBI\jdk160\bin\jar –xvf C:\OBI\Oracle_BI1\bifoundation\jee\analytics.ear), so you will probably want to create a
temporary directory to hold the unpacked contents and change into that directory before running the command.
The ear contains a META-INF directory and two war files, analytics.war and analytics-ws.war
• In the META-INF directory, there is a MANIFEST.MF file, add the following line to the end of the file:
Weblogic-Application-Version: 11.1.1
Note that it has been reported that when re-applying these steps following the application of BI 11.1.1.5.0 BP2 patches, this step to update MANIFEST.MF should be ignored as the new analytics.ear file is not versioned.
• Unpack the analytics.war file to a second temporary location; it contains a default.jsp file and five top-level directories, one of which is called WEB-INF.
• in the WEB-INF directory, you will find an existing file called web.xml. Edit web.xml, for example by adding:
<error-page>
<error-code>500</error-code>
<location>/500error.jsp</location>
</error-page>
Make sure there are no hidden characters and check the quotes are correct for your platform.
• Once you have edited the web.xml , repackage the analytics.war file, again using the jar tool, and, in turn, repackage that back into the analytics.ear file.
Next we need to redeploy the analytics.ear file to Weblogic
• Log into Weblogic Admin Console and click on Deployments
• In the Change Centre at the top left, click “Lock and Edit”
• Find the analytics app and click the tickbox next to it, then click on the Update button
• In the Update Application Assistant screen, make sure the deployment path is the same as the ear file you just updated, if not change the path
• Click Next, then Finish
• In the Change Centre at the top left, click “Activate Changes” to save your changes. If you have not already done so, restart the Weblogic Admin Server and all Managed Servers