unable to add new mode to cloud9 ide - cloud9-ide

so, I've created a new mymode.js and mymode_highlight_rules.js , and put these files into the ace/lib/ace/mode directory
I've restarted cloud9 but the option is not there in the language selection
what am I doing wrong ? do I also need to add / update something else somewhere else ? ;)
thanks

If you are adding mode to ace you need to add caption and extensions to https://github.com/c9/core/blob/master/node_modules/ace/lib/ace/ext/modelist.js#L68
You can also create a cloud9 plugin as described at http://cloud9-sdk.readme.io/v0.1/docs/modes

Related

PhpStorm How to correctly configure upload shortcut?

I finally bought the PhpStorm licence. Been using it for two years and, since their doing a great job, I had to play the game and be honest.
Now I'm faced with a problem, previously I had the perfect configuration that I don't have anymore.
Every project is linked to a ftp remote host. When I edited a file locally and save with ctrl + S, it saved the file locally without uploading it.
To upload I configured the explicit save on CTRL + Maj + S (In tools > Deployment > Option).
It was perfect!
With the new version, I can't find a way to do that. I tried updating the shortcut in the settings but it always stays "On explicit save action (Ctrl + S)".
I'm missing something and it's driving me crazy... (loosing all my ftp configuration in the update did not help).
That was actually a bug: https://youtrack.jetbrains.com/issue/WI-21962
The behavior you're currently experiencing is expected.
You can assign Ctrl+S to Other | Save Document action in Keymap - this would save currently opened file only and wouldn't trigger auto-upload.

Edit Exploit in Metasploit

How can I change Metasploit module source, I want to change some URL in an exploit.
I have tried the edit command and successfully edited this line to what I want, but changes are not reflected, the exploit has the same behavior as before, it looks like I haven't changed anything, but when I to try edit it again, I see my changes!
Does Metasploit save this anywhere else?
Just reload your module with reload right after you finished with edit
Do u want to edit the Metasploit framework or just one of the exploits?
If u just want to edit an exploit,find the location, edit it ,and reload all the modules by the command "reload_all".

Sublime Text - Unable to edit package settings

I am trying to edit the settings for an installed package for Sublime Text.
Background:
Installed Laravel 4 Artisan package via Package Control: Install Package.
Trying to run Artisan commands returns an error message:
Laravel requires the Mcrypt PHP extension.
Via terminal, artisan works fine. This leads me to believe that the PHP version used by Laravel 4 Artisan in Sublime Text is different from the version set up in my .bash_profile.
In the terminal, which php returns /Applications/MAMP/bin/php/php5.4.10/bin/php
In Sublime Text, Package Settings > Laravel 4 Artisan > Settings - Default points to:
{
"php_path": "php"
}
These settings seem to be read-only. I cannot even change the text, let alone save it with the new PHP location.
Any ideas or am I missing something simple?
problem solved. The problem is me being a Sublime Text noob.
Solution for those of you who don't know:
Sublime text packages appear to have various settings modes. A default mode and a user mode.
If you copy the contents of default mode over to user mode, then edit user mode. Then I believe that the settings in user will extend / override the settings in the default mode.
From what I can see, you cannot edit the settings in default.
So instead of { "php_path": "php" }, user settings should be something like the following depending on your php setup.
{
"php_path": "/Applications/MAMP/bin/php/php5.4.10/bin/php"
}
Happy to see you solved your problem. I'll clarify a bit to help anyone else who comes across this. You are correct in the fact that the settings are merged. The load order determines how these files are merged. The User folder is always last. So whatever you specify there will always be taken over that of previous configurations.
Depending on how you installed your plugin, the "Default" settings that came with the plugin may be overwritten. So you don't want to make any changes there that you hope to persist, so placing them in the User folder is the correct thing to do. As an additional note, you don't have to copy the entire contents of the "default" settings. Rather, you only need to specify the settings you want to override. Things will be merged appropriately.
One last thing, I don't believe ST2 makes the default settings read only. I do know ST3 does (well based on where it is installed). Be sure to post questions with the correct tag (sublimetext3 in this case). Was to long for a comment, but I hope this helps clarify things for you.
Also in case anyone is still struggling after doing this, remember to restart SublimeText to enable.

Setting up phpstorm 4 with XAMPP on Windows 7

I need help setting up phpstorm (4.0) with XAMPP which is at the default location c:\xampp\htdocs. I create all my projects at c:\xampp\htdocs\projectname.
Here are the things I have already done:
Setup the PHP interpretator by going to settings and then PHP (main menu)
Go to PHP > Servers and then
To setup run configuration I have the done the following:
Now when I run using the above configuration it just takes me to localhost in my browser, instead of the file I am editing (http://localhost instead of localhost/myproject/myfile.php).
What am I missing? I read the help topics of phpstorm and googled a lot but still couldn't figure it out.
Turns out you don't need to set up run configuration. The answer lies in setting up the mapping in the deployment tab in settings.
(assuming that you are creating your projects in c:\xampp\htdocs)
To do that go to settings (Ctrl + Alt + S) and then choose deployment:
Under mappings tab, it should look like this:
And after that you can view the file in the browser through this menu:
Check the answer to this question. If you need to debug, the recommended way to do it is zero configuration debugging.

PhpStorm configuration for automatic creation of the class namespace use statement like in ZendStudio

I like ZendStudio feature when after typing class name and pressing "Enter" it automatically adds namespace use statement into the head of the script file.
Is it possible to do the same in the PhpStorm IDE?
Not sure if this has been there all the time, or if it a new addition but it can be done already.
On my case, you get on top of the class that you want the use imported and you press alt+Enter. A popup allowing you to select which namespace you want to import pops up.
You can see a more graphical explanation here:
PHP Storm Tricks: Add your USE Statements Automatically!
I just wanted to disable it (it's native and enabled by default now) and found this SO thread.
For people like me, here's where the setting:
Editor > Auto-import > PHP - Enable auto-import in namespace scope
Please vote http://youtrack.jetbrains.net/issue/WI-1362
In PHPStorm 6.0.3 on Mac (and presumably other platforms) you should follow the advice given by #Savageman. It worked for me.
Go to "Settings" (Ctrl+Alt+S) > "Code Style > PHP" (I'm assuming you're using PS 3.0)

Resources