This repo contains the code styles for all JetBrains based IDEs used at dreipol
- Open your IDE
- Choose Menu File > Import Settings
- Select the jar for your IDE
pycharm.jar
- 120 chars line width
- Default Python settings
- dreipol drontend (JS/CSS/HTML) formatting
- reformat_and_save: Rearranges, reformats and organizes imports, then saves the file
android_studio.jar
- Spaces instead of tabs
- Code Arrangement and field prefixes
- Method and Field arrangement
- XML Linebreaks
- reformat_and_save: Rearranges, reformats and organizes imports, then saves the file
appcode.jar
- Spaces instead of tabs
- Code Arrangement
- Method and Field arrangement
- reformat_and_save: Reformats, indents and organizes imports, then saves the file
Prefixes your git commit message with the name of the current branch. You can link the script by executing the following commands:
chmod a+x ~/Documents/Repositories/codestyle/git-templates/hooks/prepare-commit-msg
mkdir ~/Documents/Repositories/[REPOSITORY]/.git/hooks
ln -s ~/Documents/Repositories/codestyle/git-templates/hooks/prepare-commit-msg ~/Documents/Repositories/[REPOSITORY]/.git/hooks/prepare-commit-msg
or you can change your global config to use the template folder from codestyle:
git config --global init.templatedir '~/Documents/Repositories/codestyle/git-templates'
New repositories will have the hooks automatically. For existing repositories, you have to git init
in the repository to add the templates.
Please note that if the hook-script changes you'll have to do the following: rm -f .git/hooks/prepare-commit-msg && git init