What IDE do you use?

Please post any questions about developing your plugin here. Please use the search function before posting!
Jake
Junior Member
Posts: 19
Joined: Sun Oct 04, 2015 7:54 pm

What IDE do you use?

Postby Jake » Sun Oct 04, 2015 8:11 pm

Hello folks, C# developer here. I discovered SourcePython just today and it has me intrigued. A few months back I searched for a SM alternative with no luck before I began development on some plugins. Well, it's too late to turn back now and port my plugins to SourcePython, but I think any future development I do for Source Engine servers will be done with SourcePython :)

I'm curious what IDE everybody uses? I've adapted to Visual Studio, though haven't done much with Python in it. Could IntelliSense integration be a possibility?
User avatar
Ayuto
Project Leader
Posts: 2195
Joined: Sat Jul 07, 2012 8:17 am
Location: Germany

Postby Ayuto » Sun Oct 04, 2015 9:04 pm

Hi and welcome to Source.Python!

For Python code I'm using Notepad++ and never tried something different. For the internal C++ code I'm using Visual Studio 2010.
User avatar
Mahi
Senior Member
Posts: 236
Joined: Wed Aug 29, 2012 8:39 pm
Location: Finland

Postby Mahi » Sun Oct 04, 2015 11:08 pm

IntelliSense works just fine, but there are better alternatives.
If you want a full IDE with all the cool features, you should take a look at PyCharm. But before you do, please read through this post!
A full IDE instead of a text-editor that's capable of doing IDE stuff is a bit of an overkill for Python, and PyCharm ain't that good to be honest, there are better routes to choose from.
So what are the better routes?

TL;DR:
Want something simple that you can learn quickly? Go with Sublime Text 3.
Got loads of time and motivation to learn superior text editing? Learn Vim and then use whatever editor you want because everything supports Vim's keybindings.

Now the not so TL;DR...

BRONZE: Notepad++ and other bad text editors.
These are all just fine, they're simple and do what a text editor should do, plus more.
If you want simplicity, it's an OK choice.

SILVER: Sublime Text 3
It does everything Notepad++ does, and it does it better. And it's even more simple. And it also does more. Way more. Download it already. Just ignore the Notepad++ section, go for Sublime Text 3. You too Ayuto.

No seriously, this thing comes with a Command Palette!!
Wanna do something and can't remember the keystroke? Instead of finding this mysterious "something" through the 7 menus from the editor's menubar, hit Ctrl+P (the only keystroke you need to remember) and you can search for anything.
You can seriously do everything with it: changing settings, run your program through python interpreter, open internet browser for HTML viewing, etc...
This feature alone is enough to throw your Notepad++ away.

Sublime also has multiple cursors.
This is just awesome, it's the thing I am missing after moving away from Sublime. You can have multiple cursors in different places at once, and edit all of them simultaneously. It's like Find & Replace, except it's 100 times better! Just try it!
This feature alone is enough to throw your Notepad++ away.

The plugins. Sublime Text 3 has by far the best plugin system I've ever seen.
You download Plugin Manager by executing one command through the Sublime's console, and then you can download any plugin by accessing your command palette (Ctrl+P remember?) and just type "ins plu" or "inst plug" or anything that resembles "install plugins". You then get a list of all plugins available on GitHub (it downloads them directly from GitHub :o ) and you can search for plugins right through Sublime.
Oh, did I mention? They're all coded in Python. So you can code your own anytime you want.
This feature alone is enough to throw your Notepad++ away.

Also, GitHub's Atom editor is very similar to Sublime Text 3 (it's like 95% the same...) so it's also worth mentioning.

GOLD: Vim and Emacs
The two superior text editors, Vim and Emacs (please don't google vim vs emacs, it's worse than console vs PC...).
I personally chose Vim due to its modes, because Emacs requires (allows? vim vs emacs.) you to hit Ctrl and Alt for every keystroke, whereas Vim has separate modes for writing and moving/selecting/etc.

Both Vim and Emacs require you to forget every keystroke you've ever heard of.
Wanna save a file? No more Ctrl+S.
Wanna copy and paste? No more Ctrl+C & Ctrl+V.
Wanna move around in a file? No more arrow keys.

The learning curve is huge. You have to (you get to!!) learn how to move without your arrow keys.
But if you have enough motivation and time to learn one of these (it takes months to learn, years to master), you're gonna have the best text editor out there.
Whenever I have to touch my arrow keys or any GUI element while using an other text editor, my brain explodes from the impracticality.
It's a freaking text editor, why am I moving my fingers away from the text keys??
Fun fact: I'm actually using a Vim mode for Chrome to write this very text! No more arrow keys for me.

These two are simply better at editing text than anything else out there, so you should give them a try.
There's a keybind for everything, and if there's not, you can make one.
But if the learning curve is too much for you, you can always go use Sublime Text 3 which is still way superior to whatever you're currently using.

Vim vs Emacs
Emacs is often referenced as an OS of its own, since you can do almost anything with it. I'm a Vim fan who has tried both, and I admit, Emacs is better than Vim.
But while Emacs is capable of replacing your whole OS with its awesomeness, Vim is superior to Emacs (which again is superior to everything else but Vim) with its keystrokes and commands that allow you to "fly" through your text instead of using that clunky mouse or arrow keys. Sure, Emacs has these too, but Vim's bindings are simply better. So Emacs is overall better, but Vim is better at purely editing plain text.

Now then. Vim is better at purely editing text, but Emacs is better at everything else with its plugins and everything. So if you wanna go really hardcore, you go with Emacs and use evil-mode, which basically adds Vim's keybindings to Emacs.
But there's more!! If this sounds fucking retarded to you, you should consider learning Vim and then you can use any text editor that supports Vim keybindings!! That includes Visual Studio, PyCharm, Sublime, Emacs, etc! Vim's custom keybindings are so good that most other text editors actually go through the trouble of implementing ways to use Vim through the other editor!
So if you learn Vim, you can then go any route you want and you're gonna be faster at typing than anyone else.
Predz
Senior Member
Posts: 158
Joined: Wed Aug 08, 2012 9:05 pm
Location: Bristol, United Kingdom

Postby Predz » Mon Oct 05, 2015 8:30 am

For managing your own projects I advice using Sublime Text, as Mahi said, the ease of use in this product is crazy. I still have Notepad ++ installed specifically for reading other peoples projects and it is good, but still prefer Sublime for the ease of use when wanting to modify a whole project.
User avatar
Ayuto
Project Leader
Posts: 2195
Joined: Sat Jul 07, 2012 8:17 am
Location: Germany

Postby Ayuto » Mon Oct 05, 2015 9:27 am

Mahi wrote:changing settings, run your program through python interpreter, open internet browser for HTML viewing, etc...
Actually, you can do that with Notepad++ as well. To run the program with a Python interpreter you only need to install a plugin.

Mahi wrote:Sublime also has multiple cursors.
Notepad++ too. :)
https://notepad-plus-plus.org/features/multi-editing.html

Mahi wrote:You download Plugin Manager by executing one command through the Sublime's console, and then you can download any plugin by accessing your command palette (Ctrl+P remember?) and just type "ins plu" or "inst plug" or anything that resembles "install plugins". You then get a list of all plugins available on GitHub (it downloads them directly from GitHub :o ) and you can search for plugins right through Sublime.
Oh, did I mention? They're all coded in Python. So you can code your own anytime you want.
Notepad++ also has a plugin manager and AFAIK the plugin are written in Python.

I might take a look at Sublime Text 3. Maybe there are really some neat features that don't exist in Notepad++.
User avatar
Mahi
Senior Member
Posts: 236
Joined: Wed Aug 29, 2012 8:39 pm
Location: Finland

Postby Mahi » Mon Oct 05, 2015 10:13 am

Ayuto wrote:Actually, you can do that with Notepad++ as well. To run the program with a Python interpreter you only need to install a plugin.

Mahi wrote:Sublime also has multiple cursors.
Notepad++ too. :)
https://notepad-plus-plus.org/features/multi-editing.html

Mahi wrote:You download Plugin Manager by executing one command through the Sublime's console, and then you can download any plugin by accessing your command palette (Ctrl+P remember?) and just type "ins plu" or "inst plug" or anything that resembles "install plugins". You then get a list of all plugins available on GitHub (it downloads them directly from GitHub :o ) and you can search for plugins right through Sublime.
Oh, did I mention? They're all coded in Python. So you can code your own anytime you want.
Notepad++ also has a plugin manager and AFAIK the plugin are written in Python.

I might take a look at Sublime Text 3. Maybe there are really some neat features that don't exist in Notepad++.

WHAT?? Notepad++ didn't have any of these before! :(
I'm downloading it now, gotta give it a try!

Edit:
Okay uninstalled, no thanks. :D

I misunderstood the part where you said "you can do that with Notepad++ as well", I thought you meant Notepad++ had a command palette, but you only meant that those things I mentioned as examples can be done in Notepad++ too. The fancy thing is not that you can do a lot in Sublime, it's that you can do a lot with the command palette. Whenever you wanna do something, you hit Ctrl+P and search for any action. It's not the actions that are cool, it's the command palette.


Tried it, threw it away. Try Sublime 3's multi-cursor support, cause this isn't anything similar.
Why would I wanna create multiple cursors using my mouse button 1? Or hold down alt to create multiple cursors right next to the previous ones?
In sublime, I highlight a word (ctrl+d) or a sentence, then I hit ctrl+d to find the next occurrence of that word/sentence (and select it, and add a cursor to it), and I'm free to select any occurrences I want. You can skip occurrences with ctrl+k, ctrl+d.
You can also just hit Alt+F3 to select all occurrences of the selection, or drag using my mouse3 to create multiple cursors everywhere I drag (similar to Notepad++, but I can DRAG through the whole file in 2 seconds, instead of having to click 400 times on each line).
Once you learn to use the multiple cursors (3 shortcuts: ctrl+d, alt+F3, mouse3), you never wanna go back. I guarantee.

Ayuto wrote:Notepad++ also has a plugin manager and AFAIK the plugin are written in Python.

It seems like Notepad++'s plugins are done with C++: https://notepad-plus-plus.org/contribute/plugin-howto.html
And they're 10 times harder to find and install. And there are so few of them, all of which do so little. Sublime's Package Manager is just so perfect and easy to use, and there's a plugin for everything!

Predz wrote:For managing your own projects I advice using Sublime Text, as Mahi said, the ease of use in this product is crazy. I still have Notepad ++ installed specifically for reading other peoples projects and it is good, but still prefer Sublime for the ease of use when wanting to modify a whole project.
I don't see how is Notepad++ better at reading projects than Sublime? I'm not saying Sublime is better than Notepad++ either, I mean, you're just reading text? But if you're already using Sublime, why have Notepad++ too? Just curious.

Return to “Plugin Development Support”

Who is online

Users browsing this forum: No registered users and 59 guests