Skip to content

Instantly share code, notes, and snippets.

@p1nox
Last active June 21, 2022 14:02
Show Gist options
  • Save p1nox/7275562 to your computer and use it in GitHub Desktop.
Save p1nox/7275562 to your computer and use it in GitHub Desktop.
Editors config
  • bash

      # spacemacs config
      alias spacemacs-insecure="emacs --insecure"
      alias spacemacs-start="emacs -nw --daemon"
      alias spacemacs-now="emacsclient -c . &"
      alias spacemacs-client="emacsclient -c"
      alias smi=spacemacs-insecure
      alias sms=spacemacs-start
      alias smn=spacemacs-now
      alias smc=spacemacs-client
    
  • layers

      (version-control :variables
                       version-control-diff-tool 'git-gutter+)
    
  • init

Smooth scroll for spacemacs (syl20bnr/spacemacs#1781 (comment))

;;; scroll one line at a time (less "jumpy" than defaults)
(setq mouse-wheel-scroll-amount '(2 ((shift) . 1))) ;; two lines at a time
(setq mouse-wheel-progressive-speed nil) ;; don't accelerate scrolling
(setq mouse-wheel-follow-mouse 't) ;; scroll window under mouse
;; mini buffers graph config
(setq ns-use-srgb-colorspace nil)
(setq powerline-default-separator 'utf-8)
;; indentation javascript
(setq-default
 ;; js2-mode
 js2-basic-offset 2
 js-indent-level 2
 react-indent-level 2
 javascript-indent-level 2
 standard-indent 2
 ;; web-mode
 css-indent-offset 2
 web-mode-markup-indent-offset 2
 web-mode-css-indent-offset 2
 web-mode-code-indent-offset 2
 web-mode-attr-indent-offset 2
 indent-tabs-mode t)
 
 ;; other!
 standard-indent 2
 tab-width 2
 indent-tabs-mode nil
 js-indent-level 2
 js2-basic-offset 2
 js2-strict-semi-warning nil
 js2-missing-semi-one-line-override nil
 web-mode-markup-indent-offset 2
 web-mode-css-indent-offset 2
 web-mode-code-indent-offset 2
 web-mode-indent-style 2
  • user-config ;; osx redo fixed (global-set-key (kbd "s-Z") 'undo-tree-redo) ;; Show line numbers by default (global-linum-mode) ;; Word length (add-hook 'python-mode-hook #'(lambda () (modify-syntax-entry ?_ "w"))) (add-hook 'ruby-mode-hook #'(lambda () (modify-syntax-entry ?_ "w"))) (add-hook 'js2-mode-hook #'(lambda () (modify-syntax-entry ?_ "w")))

  • Other


Emacs.app was installed to:
  /usr/local/opt/emacs-plus

To link the application to default Homebrew App location:
  brew linkapps
or:
  ln -s /usr/local/opt/emacs-plus/Emacs.app /Applications

--natural-title-bar option was removed from this formula, in order to
  duplicate its effect add following line to your init.el file
  (add-to-list 'default-frame-alist '(ns-transparent-titlebar . t))
  (add-to-list 'default-frame-alist '(ns-appearance . dark))
or:
  (add-to-list 'default-frame-alist '(ns-transparent-titlebar . t))
  (add-to-list 'default-frame-alist '(ns-appearance . light))

If you are using macOS Mojave, please note that most of the experimental
options are forbidden on Mojave. This is temporary decision.

Config

  • Default:

      ...
      "tab_size": 2,
      "translate_tabs_to_spaces": true,
      ...
    
  • Gitgutter

  • TrailingSpaces

      { "keys": ["ctrl+shift+t"], "command": "delete_trailing_spaces" }
    
  • Themes: [cmd + ,]

    Soda

              "theme": "Soda Dark.sublime-theme"
              "color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme"
    

    Brogrammer

              "theme": "Brogrammer.sublime-theme",
              "color_scheme": "Packages/Theme - Brogrammer/brogrammer.tmTheme"
    

    Material Theme (OndeDark)

              "theme": "Material-Theme-Darker.sublime-theme",
              "color_scheme": "Packages/Material Theme/schemes/Material-Theme-Darker.tmTheme"
    

https://packagecontrol.io/packages/BracketHighlighter

https://github.com/oliverseal/tech49-theme

https://github.com/dempfi/ayu

  • Color Scheme

Create scheme: https://tmtheme-editor.herokuapp.com/#!/editor/local/sublime-spacemacs.tmTheme

Install package: https://packagecontrol.io/packages/Colorsublime

Place custom scheme inside:

  1. Prefences -> Browse Packages...
  2. Add theme package into: Packages/Colorsublime - Themes/cache/Colorsublime-Themes-master/themes

Sublime - Spacemacs color scheme https://gist.github.com/p1nox/a0b35a874aafe66dced6884ce9a126bd | https://github.com/M4he/spacemacs-colors-sublime/blob/master/Spacemacs.tmTheme

# Add Visual Studio Code (code)
export PATH="$PATH:/Applications/Visual Studio Code.app/Contents/Resources/app/bin"

# personal
{
    "editor.fontFamily": "Source Code Pro",
    "editor.fontSize": 13,
    "window.zoomLevel": 0,
    "workbench.colorTheme": "Activate UMBRA protocol",
    "javascript.updateImportsOnFileMove.enabled": "never"
}
* Source Code Pro
https://github.com/adobe-fonts/source-code-pro

{
    "editor.fontFamily": "Source Code Pro",
    "editor.fontSize": 13
}

* JetBrains Mono
https://www.jetbrains.com/lp/mono/
https://github.com/JetBrains/JetBrainsMono

{
    "editor.fontFamily": "JetBrains Mono",
    "editor.fontSize": 13,
    "editor.fontLigatures": true
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment