SHARE
TWEET

Untitled

a guest Aug 13th, 2019 104 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ;; -*- mode: emacs-lisp; lexical-binding: t -*-
  2. ;; This file is loaded by Spacemacs at startup.
  3. ;; It must be stored in your home directory.
  4.  
  5. (defun dotspacemacs/layers ()
  6.   "Layer configuration:
  7. This function should only modify configuration layer settings."
  8.   (setq-default
  9.    ;; Base distribution to use. This is a layer contained in the directory
  10.    ;; `+distribution'. For now available distributions are `spacemacs-base'
  11.    ;; or `spacemacs'. (default 'spacemacs)
  12.    dotspacemacs-distribution 'spacemacs
  13.  
  14.    ;; Lazy installation of layers (i.e. layers are installed only when a file
  15.    ;; with a supported type is opened). Possible values are `all', `unused'
  16.    ;; and `nil'. `unused' will lazy install only unused layers (i.e. layers
  17.    ;; not listed in variable `dotspacemacs-configuration-layers'), `all' will
  18.    ;; lazy install any layer that support lazy installation even the layers
  19.    ;; listed in `dotspacemacs-configuration-layers'. `nil' disable the lazy
  20.    ;; installation feature and you have to explicitly list a layer in the
  21.    ;; variable `dotspacemacs-configuration-layers' to install it.
  22.    ;; (default 'unused)
  23.    dotspacemacs-enable-lazy-installation 'unused
  24.  
  25.    ;; If non-nil then Spacemacs will ask for confirmation before installing
  26.    ;; a layer lazily. (default t)
  27.    dotspacemacs-ask-for-lazy-installation t
  28.  
  29.    ;; If non-nil layers with lazy install support are lazy installed.
  30.    ;; List of additional paths where to look for configuration layers.
  31.    ;; Paths must have a trailing slash (i.e. `~/.mycontribs/')
  32.    dotspacemacs-configuration-layer-path '()
  33.  
  34.    ;; List of configuration layers to load.
  35.    dotspacemacs-configuration-layers
  36.    '(vimscript
  37.      rust
  38.      python
  39.      pdf
  40.      ;; ----------------------------------------------------------------
  41.      ;; Example of useful layers you may want to use right away.
  42.      ;; Uncomment some layer names and press `SPC f e R' (Vim style) or
  43.      ;; `M-m f e R' (Emacs style) to install them.
  44.      ;; ----------------------------------------------------------------
  45.      helm
  46.      ranger
  47.      prodigy
  48.      ;; better-defaults
  49.      yaml
  50.      ;; org
  51.      (shell :variables
  52.             ;shell-default-term-shell "/bin/zsh"
  53.             shell-default-height 30
  54.             shell-default-position 'bottom)
  55.      ;; spell-checking
  56.      ;; syntax-checking
  57.      ;; version-control
  58.      sql
  59.      yaml
  60.      html
  61.      asciidoc
  62.      (go :variables
  63.          go-format-before-save t
  64.          go-use-gometalinter t
  65.          gofmt-command "goimports")
  66.      javascript
  67.      typescript
  68.      clojure
  69.      docker
  70.      ;; (auto-completion :variables
  71.      ;;                  auto-completion-enable-snippets-in-popup t)
  72.      auto-completion
  73.      emacs-lisp
  74.      git
  75.      ;; (version-control :variables
  76.      ;;                  ;; version-control-diff-tool 'diff-hl
  77.      ;;                  ;; version-control-diff-side 'left
  78.      ;;                  version-control-global-margin 't)
  79.      (spell-checking :variables spell-checking-enable-by-default nil)
  80.      syntax-checking
  81.      themes-megapack
  82.      gtags
  83.      )
  84.  
  85.  
  86.    ;; List of additional packages that will be installed without being
  87.    ;; wrapped in a layer. If you need some configuration for these
  88.    ;; packages, then consider creating a layer. You can also put the
  89.    ;; configuration in `dotspacemacs/user-config'.
  90.    ;; To use a local version of a package, use the `:location' property:
  91.    ;; '(your-package :location "~/path/to/your-package/")
  92.    ;; Also include the dependencies as they will not be resolved automatically.
  93.    dotspacemacs-additional-packages '()
  94.  
  95.    ;; A list of packages that cannot be updated.
  96.    dotspacemacs-frozen-packages '()
  97.  
  98.    ;; A list of packages that will not be installed and loaded.
  99.    dotspacemacs-excluded-packages '()
  100.  
  101.    ;; Defines the behaviour of Spacemacs when installing packages.
  102.    ;; Possible values are `used-only', `used-but-keep-unused' and `all'.
  103.    ;; `used-only' installs only explicitly used packages and deletes any unused
  104.    ;; packages as well as their unused dependencies. `used-but-keep-unused'
  105.    ;; installs only the used packages but won't delete unused ones. `all'
  106.    ;; installs *all* packages supported by Spacemacs and never uninstalls them.
  107.    ;; (default is `used-only')
  108.    dotspacemacs-install-packages 'used-only))
  109.  
  110. (defun dotspacemacs/init ()
  111.   "Initialization:
  112. This function is called at the very beginning of Spacemacs startup,
  113. before layer configuration.
  114. It should only modify the values of Spacemacs settings."
  115.   ;; This setq-default sexp is an exhaustive list of all the supported
  116.   ;; spacemacs settings.
  117.   (setq-default
  118.    ;; If non-nil then enable support for the portable dumper. You'll need
  119.    ;; to compile Emacs 27 from source following the instructions in file
  120.    ;; EXPERIMENTAL.org at to root of the git repository.
  121.    ;; (default nil)
  122.    dotspacemacs-enable-emacs-pdumper nil
  123.  
  124.    ;; Name of executable file pointing to emacs 27+. This executable must be
  125.    ;; in your PATH.
  126.    ;; (default "emacs")
  127.    dotspacemacs-emacs-pdumper-executable-file "emacs"
  128.  
  129.    ;; Name of the Spacemacs dump file. This is the file will be created by the
  130.    ;; portable dumper in the cache directory under dumps sub-directory.
  131.    ;; To load it when starting Emacs add the parameter `--dump-file'
  132.    ;; when invoking Emacs 27.1 executable on the command line, for instance:
  133.    ;;   ./emacs --dump-file=~/.emacs.d/.cache/dumps/spacemacs.pdmp
  134.    ;; (default spacemacs.pdmp)
  135.    dotspacemacs-emacs-dumper-dump-file "spacemacs.pdmp"
  136.  
  137.    ;; If non-nil ELPA repositories are contacted via HTTPS whenever it's
  138.    ;; possible. Set it to nil if you have no way to use HTTPS in your
  139.    ;; environment, otherwise it is strongly recommended to let it set to t.
  140.    ;; This variable has no effect if Emacs is launched with the parameter
  141.    ;; `--insecure' which forces the value of this variable to nil.
  142.    ;; (default t)
  143.    dotspacemacs-elpa-https t
  144.  
  145.    ;; Maximum allowed time in seconds to contact an ELPA repository.
  146.    ;; (default 5)
  147.    dotspacemacs-elpa-timeout 5
  148.  
  149.    ;; Set `gc-cons-threshold' and `gc-cons-percentage' when startup finishes.
  150.    ;; This is an advanced option and should not be changed unless you suspect
  151.    ;; performance issues due to garbage collection operations.
  152.    ;; (default '(100000000 0.1))
  153.    dotspacemacs-gc-cons '(100000000 0.1)
  154.  
  155.    ;; If non-nil then Spacelpa repository is the primary source to install
  156.    ;; a locked version of packages. If nil then Spacemacs will install the
  157.    ;; latest version of packages from MELPA. (default nil)
  158.    dotspacemacs-use-spacelpa nil
  159.  
  160.    ;; If non-nil then verify the signature for downloaded Spacelpa archives.
  161.    ;; (default nil)
  162.    dotspacemacs-verify-spacelpa-archives nil
  163.  
  164.    ;; If non-nil then spacemacs will check for updates at startup
  165.    ;; when the current branch is not `develop'. Note that checking for
  166.    ;; new versions works via git commands, thus it calls GitHub services
  167.    ;; whenever you start Emacs. (default nil)
  168.    dotspacemacs-check-for-update nil
  169.  
  170.    ;; If non-nil, a form that evaluates to a package directory. For example, to
  171.    ;; use different package directories for different Emacs versions, set this
  172.    ;; to `emacs-version'. (default 'emacs-version)
  173.    dotspacemacs-elpa-subdirectory 'emacs-version
  174.  
  175.    ;; One of `vim', `emacs' or `hybrid'.
  176.    ;; `hybrid' is like `vim' except that `insert state' is replaced by the
  177.    ;; `hybrid state' with `emacs' key bindings. The value can also be a list
  178.    ;; with `:variables' keyword (similar to layers). Check the editing styles
  179.    ;; section of the documentation for details on available variables.
  180.    ;; (default 'vim)
  181.    dotspacemacs-editing-style 'vim
  182.  
  183.    ;; Specify the startup banner. Default value is `official', it displays
  184.    ;; the official spacemacs logo. An integer value is the index of text
  185.    ;; banner, `random' chooses a random text banner in `core/banners'
  186.    ;; directory. A string value must be a path to an image format supported
  187.    ;; by your Emacs build.
  188.    ;; If the value is nil then no banner is displayed. (default 'official)
  189.    dotspacemacs-startup-banner 'official
  190.  
  191.    ;; List of items to show in startup buffer or an association list of
  192.    ;; the form `(list-type . list-size)`. If nil then it is disabled.
  193.    ;; Possible values for list-type are:
  194.    ;; `recents' `bookmarks' `projects' `agenda' `todos'.
  195.    ;; List sizes may be nil, in which case
  196.    ;; `spacemacs-buffer-startup-lists-length' takes effect.
  197.    dotspacemacs-startup-lists '((recents . 5)
  198.                                 (projects . 7))
  199.  
  200.    ;; True if the home buffer should respond to resize events. (default t)
  201.    dotspacemacs-startup-buffer-responsive t
  202.  
  203.    ;; Default major mode for a new empty buffer. Possible values are mode
  204.    ;; names such as `text-mode'; and `nil' to use Fundamental mode.
  205.    ;; (default `text-mode')
  206.    dotspacemacs-new-empty-buffer-major-mode 'text-mode
  207.  
  208.    ;; Default major mode of the scratch buffer (default `text-mode')
  209.    dotspacemacs-scratch-mode 'text-mode
  210.  
  211.    ;; Initial message in the scratch buffer, such as "Welcome to Spacemacs!"
  212.    ;; (default nil)
  213.    dotspacemacs-initial-scratch-message nil
  214.  
  215.    ;; List of themes, the first of the list is loaded when spacemacs starts.
  216.    ;; Press `SPC T n' to cycle to the next theme in the list (works great
  217.    ;; with 2 themes variants, one dark and one light)
  218.    dotspacemacs-themes '(spacemacs-dark
  219.                          spacemacs-light)
  220.  
  221.    ;; Set the theme for the Spaceline. Supported themes are `spacemacs',
  222.    ;; `all-the-icons', `custom', `doom', `vim-powerline' and `vanilla'. The
  223.    ;; first three are spaceline themes. `doom' is the doom-emacs mode-line.
  224.    ;; `vanilla' is default Emacs mode-line. `custom' is a user defined themes,
  225.    ;; refer to the DOCUMENTATION.org for more info on how to create your own
  226.    ;; spaceline theme. Value can be a symbol or list with additional properties.
  227.    ;; (default '(spacemacs :separator wave :separator-scale 1.5))
  228.    dotspacemacs-mode-line-theme '(all-the-icons :separator arrow :separator-scale 1.5)
  229.  
  230.    ;; If non-nil the cursor color matches the state color in GUI Emacs.
  231.    ;; (default t)
  232.    dotspacemacs-colorize-cursor-according-to-state t
  233.  
  234.    ;; Default font or prioritized list of fonts.
  235.    dotspacemacs-default-font '("Dank Mono"
  236.                                :size 10.0
  237.                                :weight normal
  238.                                :width normal)
  239.  
  240.    ;; The leader key (default "SPC")
  241.    dotspacemacs-leader-key "SPC"
  242.  
  243.    ;; The key used for Emacs commands `M-x' (after pressing on the leader key).
  244.    ;; (default "SPC")
  245.    dotspacemacs-emacs-command-key "SPC"
  246.  
  247.    ;; The key used for Vim Ex commands (default ":")
  248.    dotspacemacs-ex-command-key ":"
  249.  
  250.    ;; The leader key accessible in `emacs state' and `insert state'
  251.    ;; (default "M-m")
  252.    dotspacemacs-emacs-leader-key "M-m"
  253.  
  254.    ;; Major mode leader key is a shortcut key which is the equivalent of
  255.    ;; pressing `<leader> m`. Set it to `nil` to disable it. (default ",")
  256.    dotspacemacs-major-mode-leader-key ","
  257.  
  258.    ;; Major mode leader key accessible in `emacs state' and `insert state'.
  259.    ;; (default "C-M-m")
  260.    dotspacemacs-major-mode-emacs-leader-key "C-M-m"
  261.  
  262.    ;; These variables control whether separate commands are bound in the GUI to
  263.    ;; the key pairs `C-i', `TAB' and `C-m', `RET'.
  264.    ;; Setting it to a non-nil value, allows for separate commands under `C-i'
  265.    ;; and TAB or `C-m' and `RET'.
  266.    ;; In the terminal, these pairs are generally indistinguishable, so this only
  267.    ;; works in the GUI. (default nil)
  268.    dotspacemacs-distinguish-gui-tab nil
  269.  
  270.    ;; Name of the default layout (default "Default")
  271.    dotspacemacs-default-layout-name "Default"
  272.  
  273.    ;; If non-nil the default layout name is displayed in the mode-line.
  274.    ;; (default nil)
  275.    dotspacemacs-display-default-layout nil
  276.  
  277.    ;; If non-nil then the last auto saved layouts are resumed automatically upon
  278.    ;; start. (default nil)
  279.    dotspacemacs-auto-resume-layouts nil
  280.  
  281.    ;; If non-nil, auto-generate layout name when creating new layouts. Only has
  282.    ;; effect when using the "jump to layout by number" commands. (default nil)
  283.    dotspacemacs-auto-generate-layout-names nil
  284.  
  285.    ;; Size (in MB) above which spacemacs will prompt to open the large file
  286.    ;; literally to avoid performance issues. Opening a file literally means that
  287.    ;; no major mode or minor modes are active. (default is 1)
  288.    dotspacemacs-large-file-size 1
  289.  
  290.    ;; Location where to auto-save files. Possible values are `original' to
  291.    ;; auto-save the file in-place, `cache' to auto-save the file to another
  292.    ;; file stored in the cache directory and `nil' to disable auto-saving.
  293.    ;; (default 'cache)
  294.    dotspacemacs-auto-save-file-location 'cache
  295.  
  296.    ;; Maximum number of rollback slots to keep in the cache. (default 5)
  297.    dotspacemacs-max-rollback-slots 5
  298.  
  299.    ;; If non-nil, the paste transient-state is enabled. While enabled, after you
  300.    ;; paste something, pressing `C-j' and `C-k' several times cycles through the
  301.    ;; elements in the `kill-ring'. (default nil)
  302.    dotspacemacs-enable-paste-transient-state nil
  303.  
  304.    ;; Which-key delay in seconds. The which-key buffer is the popup listing
  305.    ;; the commands bound to the current keystroke sequence. (default 0.4)
  306.    dotspacemacs-which-key-delay 0.4
  307.  
  308.    ;; Which-key frame position. Possible values are `right', `bottom' and
  309.    ;; `right-then-bottom'. right-then-bottom tries to display the frame to the
  310.    ;; right; if there is insufficient space it displays it at the bottom.
  311.    ;; (default 'bottom)
  312.    dotspacemacs-which-key-position 'bottom
  313.  
  314.    ;; Control where `switch-to-buffer' displays the buffer. If nil,
  315.    ;; `switch-to-buffer' displays the buffer in the current window even if
  316.    ;; another same-purpose window is available. If non-nil, `switch-to-buffer'
  317.    ;; displays the buffer in a same-purpose window even if the buffer can be
  318.    ;; displayed in the current window. (default nil)
  319.    dotspacemacs-switch-to-buffer-prefers-purpose nil
  320.  
  321.    ;; If non-nil a progress bar is displayed when spacemacs is loading. This
  322.    ;; may increase the boot time on some systems and emacs builds, set it to
  323.    ;; nil to boost the loading time. (default t)
  324.    dotspacemacs-loading-progress-bar t
  325.  
  326.    ;; If non-nil the frame is fullscreen when Emacs starts up. (default nil)
  327.    ;; (Emacs 24.4+ only)
  328.    dotspacemacs-fullscreen-at-startup nil
  329.  
  330.    ;; If non-nil `spacemacs/toggle-fullscreen' will not use native fullscreen.
  331.    ;; Use to disable fullscreen animations in OSX. (default nil)
  332.    dotspacemacs-fullscreen-use-non-native nil
  333.  
  334.    ;; If non-nil the frame is maximized when Emacs starts up.
  335.    ;; Takes effect only if `dotspacemacs-fullscreen-at-startup' is nil.
  336.    ;; (default nil) (Emacs 24.4+ only)
  337.    dotspacemacs-maximized-at-startup nil
  338.  
  339.    ;; If non-nil the frame is undecorated when Emacs starts up. Combine this
  340.    ;; variable with `dotspacemacs-maximized-at-startup' in OSX to obtain
  341.    ;; borderless fullscreen. (default nil)
  342.    dotspacemacs-undecorated-at-startup nil
  343.  
  344.    ;; A value from the range (0..100), in increasing opacity, which describes
  345.    ;; the transparency level of a frame when it's active or selected.
  346.    ;; Transparency can be toggled through `toggle-transparency'. (default 90)
  347.    dotspacemacs-active-transparency 90
  348.  
  349.    ;; A value from the range (0..100), in increasing opacity, which describes
  350.    ;; the transparency level of a frame when it's inactive or deselected.
  351.    ;; Transparency can be toggled through `toggle-transparency'. (default 90)
  352.    dotspacemacs-inactive-transparency 90
  353.  
  354.    ;; If non-nil show the titles of transient states. (default t)
  355.    dotspacemacs-show-transient-state-title t
  356.  
  357.    ;; If non-nil show the color guide hint for transient state keys. (default t)
  358.    dotspacemacs-show-transient-state-color-guide t
  359.  
  360.    ;; If non-nil unicode symbols are displayed in the mode line.
  361.    ;; If you use Emacs as a daemon and wants unicode characters only in GUI set
  362.    ;; the value to quoted `display-graphic-p'. (default t)
  363.    dotspacemacs-mode-line-unicode-symbols t
  364.  
  365.    ;; If non-nil smooth scrolling (native-scrolling) is enabled. Smooth
  366.    ;; scrolling overrides the default behavior of Emacs which recenters point
  367.    ;; when it reaches the top or bottom of the screen. (default t)
  368.    dotspacemacs-smooth-scrolling t
  369.  
  370.    ;; Control line numbers activation.
  371.    ;; If set to `t', `relative' or `visual' then line numbers are enabled in all
  372.    ;; `prog-mode' and `text-mode' derivatives. If set to `relative', line
  373.    ;; numbers are relative. If set to `visual', line numbers are also relative,
  374.    ;; but lines are only visual lines are counted. For example, folded lines
  375.    ;; will not be counted and wrapped lines are counted as multiple lines.
  376.    ;; This variable can also be set to a property list for finer control:
  377.    ;; '(:relative nil
  378.    ;;   :visual nil
  379.    ;;   :disabled-for-modes dired-mode
  380.    ;;                       doc-view-mode
  381.    ;;                       markdown-mode
  382.    ;;                       org-mode
  383.    ;;                       pdf-view-mode
  384.    ;;                       text-mode
  385.    ;;   :size-limit-kb 1000)
  386.    ;; When used in a plist, `visual' takes precedence over `relative'.
  387.    ;; (default nil)
  388.    dotspacemacs-line-numbers t
  389.  
  390.    ;; Code folding method. Possible values are `evil' and `origami'.
  391.    ;; (default 'evil)
  392.    dotspacemacs-folding-method 'evil
  393.  
  394.    ;; If non-nil `smartparens-strict-mode' will be enabled in programming modes.
  395.    ;; (default nil)
  396.    dotspacemacs-smartparens-strict-mode nil
  397.  
  398.    ;; If non-nil pressing the closing parenthesis `)' key in insert mode passes
  399.    ;; over any automatically added closing parenthesis, bracket, quote, etc...
  400.    ;; This can be temporary disabled by pressing `C-q' before `)'. (default nil)
  401.    dotspacemacs-smart-closing-parenthesis nil
  402.  
  403.    ;; Select a scope to highlight delimiters. Possible values are `any',
  404.    ;; `current', `all' or `nil'. Default is `all' (highlight any scope and
  405.    ;; emphasis the current one). (default 'all)
  406.    dotspacemacs-highlight-delimiters 'all
  407.  
  408.    ;; If non-nil, start an Emacs server if one is not already running.
  409.    ;; (default nil)
  410.    dotspacemacs-enable-server nil
  411.  
  412.    ;; Set the emacs server socket location.
  413.    ;; If nil, uses whatever the Emacs default is, otherwise a directory path
  414.    ;; like \"~/.emacs.d/server\". It has no effect if
  415.    ;; `dotspacemacs-enable-server' is nil.
  416.    ;; (default nil)
  417.    dotspacemacs-server-socket-dir nil
  418.  
  419.    ;; If non-nil, advise quit functions to keep server open when quitting.
  420.    ;; (default nil)
  421.    dotspacemacs-persistent-server nil
  422.  
  423.    ;; List of search tool executable names. Spacemacs uses the first installed
  424.    ;; tool of the list. Supported tools are `rg', `ag', `pt', `ack' and `grep'.
  425.    ;; (default '("rg" "ag" "pt" "ack" "grep"))
  426.    dotspacemacs-search-tools '("rg" "ag" "pt" "ack" "grep")
  427.  
  428.    ;; Format specification for setting the frame title.
  429.    ;; %a - the `abbreviated-file-name', or `buffer-name'
  430.    ;; %t - `projectile-project-name'
  431.    ;; %I - `invocation-name'
  432.    ;; %S - `system-name'
  433.    ;; %U - contents of $USER
  434.    ;; %b - buffer name
  435.    ;; %f - visited file name
  436.    ;; %F - frame name
  437.    ;; %s - process status
  438.    ;; %p - percent of buffer above top of window, or Top, Bot or All
  439.    ;; %P - percent of buffer above bottom of window, perhaps plus Top, or Bot or All
  440.    ;; %m - mode name
  441.    ;; %n - Narrow if appropriate
  442.    ;; %z - mnemonics of buffer, terminal, and keyboard coding systems
  443.    ;; %Z - like %z, but including the end-of-line format
  444.    ;; (default "%I@%S")
  445.    dotspacemacs-frame-title-format "%I@%S"
  446.  
  447.    ;; Format specification for setting the icon title format
  448.    ;; (default nil - same as frame-title-format)
  449.    dotspacemacs-icon-title-format nil
  450.  
  451.    ;; Delete whitespace while saving buffer. Possible values are `all'
  452.    ;; to aggressively delete empty line and long sequences of whitespace,
  453.    ;; `trailing' to delete only the whitespace at end of lines, `changed' to
  454.    ;; delete only whitespace for changed lines or `nil' to disable cleanup.
  455.    ;; (default nil)
  456.    dotspacemacs-whitespace-cleanup nil
  457.  
  458.    ;; Either nil or a number of seconds. If non-nil zone out after the specified
  459.    ;; number of seconds. (default nil)
  460.    dotspacemacs-zone-out-when-idle nil
  461.  
  462.    ;; Run `spacemacs/prettify-org-buffer' when
  463.    ;; visiting README.org files of Spacemacs.
  464.    ;; (default nil)
  465.    dotspacemacs-pretty-docs nil))
  466.  
  467. (defun dotspacemacs/user-env ()
  468.   "Environment variables setup.
  469. This function defines the environment variables for your Emacs session. By
  470. default it calls `spacemacs/load-spacemacs-env' which loads the environment
  471. variables declared in `~/.spacemacs.env' or `~/.spacemacs.d/.spacemacs.env'.
  472. See the header of this file for more information."
  473.   (spacemacs/load-spacemacs-env))
  474.  
  475. (defun dotspacemacs/user-init ()
  476.   "Initialization for user code:
  477. This function is called immediately after `dotspacemacs/init', before layer
  478. configuration.
  479. It is mostly for variables that should be set before packages are loaded.
  480. If you are unsure, try setting them in `dotspacemacs/user-config' first."
  481.   )
  482.  
  483. (defun dotspacemacs/user-load ()
  484.   "Library to load while dumping.
  485. This function is called only while dumping Spacemacs configuration. You can
  486. `require' or `load' the libraries of your choice that will be included in the
  487. dump."
  488.   )
  489.  
  490. (defun dotspacemacs/user-config ()
  491.   "Configuration for user code:
  492. This function is called at the very end of Spacemacs startup, after layer
  493. configuration.
  494. Put your configuration code here, except for variables that should be set
  495. before packages are loaded."
  496.   (if (eq system-type 'darwin)
  497.       (mac-auto-operator-composition-mode))
  498.  
  499.   (setq neo-theme 'all-the-icons)
  500.   (setq neo-theme (if (display-graphic-p) 'icons 'arrow))
  501.  
  502.   (add-to-list 'default-frame-alist
  503.                '(font . "Fira Code Retina"))
  504.  
  505.   (add-to-list 'load-path "$HOME/spacemac/neotree")
  506.   (require 'neotree)
  507.   (global-set-key [f8] 'neotree-toggle)
  508.  
  509.   ;; (require 'doom-themes)
  510.  
  511.   ;; ;; Global settings (defaults)
  512.   ;; (setq doom-themes-enable-bold t    ; if nil, bold is universally disabled
  513.   ;;       doom-themes-enable-italic t) ; if nil, italics is universally disabled
  514.  
  515.   ;; ;; Load the theme (doom-one, doom-molokai, etc); keep in mind that each theme
  516.   ;; ;; may have their own settings.
  517.   ;; (load-theme 'doom-solarized-dark t)
  518.  
  519.   ;; ;; Enable flashing mode-line on errors
  520.   ;; (doom-themes-visual-bell-config)
  521.  
  522.   ;; ;; Enable custom neotree theme (all-the-icons must be installed!)
  523.   ;; (doom-themes-neotree-config)
  524.   ;; ;; or for treemacs users
  525.   ;; (setq doom-themes-treemacs-theme "doom-colors") ; use the colorful treemacs theme
  526.   ;; (doom-themes-treemacs-config)
  527.  
  528.   ;; ;; Corrects (and improves) org-mode's native fontification.
  529.   ;; (doom-themes-org-config)
  530.  
  531.   ;;(setq explicit-shell-file-name "/bin/zsh")
  532.  
  533.   (setq auto-window-vscroll nil)
  534.     ;;; scroll one line at a time (less "jumpy" than defaults)
  535.   (setq mouse-wheel-scroll-amount '(2 ((shift) . 1))) ;; two lines at a time
  536.   (setq mouse-wheel-progressive-speed nil) ;; don't accelerate scrolling
  537.   (setq mouse-wheel-follow-mouse 't) ;; scroll window under mouse
  538.   ;; GOLANG SETUP
  539.   (setq flycheck-gometalinter-vendor t)
  540.   ;; only show errors
  541.   (setq flycheck-gometalinter-errors-only t)
  542.   ;; only run fast linters
  543.   (setq flycheck-gometalinter-fast t)
  544.   ;; use in tests files
  545.   ;; (setq flycheck-gometalinter-test t)
  546.   ;; disable linters
  547.   ;; Only enable selected linters
  548.   (setq flycheck-gometalinter-disable-all t)
  549.   (setq flycheck-gometalinter-enable-linters '("golint" "vet" "errcheck"))
  550.   ;; Set different deadline (default: 5s)
  551.   (setq flycheck-gometalinter-deadline "10s")
  552.  
  553.   ;; Clojure setup
  554.   ;; (setq cider-font-lock-dynamically '(macro core function var))
  555.   ;; (setq cider-save-file-on-load t)
  556.   (define-key evil-insert-state-map (kbd "C-a") 'beginning-of-line)
  557.   (define-key evil-insert-state-map (kbd "C-e") 'end-of-line)
  558.   ;; (define-key evil-insert-state-map (kbd "C-n") 'next-line)
  559.   ;; (define-key evil-insert-state-map (kbd "C-p") 'previous-line)
  560.  
  561.   ;; Clipboard section
  562.   (defun copy-to-clipboard ()
  563.     "Copies selection to x-clipboard."
  564.     (interactive)
  565.     (if (display-graphic-p)
  566.         (progn
  567.           (message "Yanked region to x-clipboard!")
  568.           (call-interactively 'clipboard-kill-ring-save)
  569.           )
  570.       (if (region-active-p)
  571.           (progn
  572.             (shell-command-on-region (region-beginning) (region-end) "pbcopy")
  573.             (message "Yanked region to clipboard!")
  574.             (deactivate-mark))
  575.         (message "No region active; can't yank to clipboard!")))
  576.     )
  577.  
  578.   (defun paste-from-clipboard ()
  579.     "Pastes from x-clipboard."
  580.     (interactive)
  581.     (if (display-graphic-p)
  582.         (progn
  583.           (clipboard-yank)
  584.           (message "graphics active")
  585.           )
  586.       (insert (shell-command-to-string "pbpaste"))
  587.       )
  588.     )
  589.  
  590.   (evil-leader/set-key "o y" 'copy-to-clipboard)
  591.   (evil-leader/set-key "o p" 'paste-from-clipboard)
  592.  
  593.   (define-key process-menu-mode-map (kbd "C-k") 'joaot/delete-process-at-point)
  594.  
  595.   (defun joaot/delete-process-at-point ()
  596.     (interactive)
  597.     (let ((process (get-text-property (point) 'tabulated-list-id)))
  598.       (cond ((and process
  599.                   (processp process))
  600.              (delete-process process)
  601.              (revert-buffer))
  602.             (t
  603.              (error "no process at point!")))))
  604.  
  605.   (setq org-emphasis-alist (quote (("!"  (:foreground "red") )
  606.                                    ("/" italic "<i>" "</i>")
  607.                                    ("_" underline "<span style=\"text-decoration:underline;\">" "</span>")
  608.                                    ("-" (:overline t) "<span style=\"text-decoration:overline;\">" "</span>")
  609.                                    ("=" org-code "<code>" "</code>" verbatim)
  610.                                    ("*" org-verbatim "<code>" "</code>" verbatim)
  611.                                    ("+" (:strike-through t) "<del>" "</del>"))))
  612.   ;; Magit hook, revert affected buffers after git commit
  613.   ;; (add-hook 'magit-post-refresh-hook 'diff-hl-magit-post-refresh)
  614.  
  615.   )
  616.  
  617. ;; Do not write anything past this comment. This is where Emacs will
  618. ;; auto-generate custom variable definitions.
  619. (defun dotspacemacs/emacs-custom-settings ()
  620.   "Emacs custom settings.
  621. This is an auto-generated function, do not modify its content directly, use
  622. Emacs customize menu instead.
  623. This function is called at the very end of Spacemacs initialization."
  624. (custom-set-variables
  625.  ;; custom-set-variables was added by Custom.
  626.  ;; If you edit it by hand, you could mess it up, so be careful.
  627.  ;; Your init file should contain only one such instance.
  628.  ;; If there is more than one, they won't work right.
  629.  '(ansi-color-names-vector
  630.    ["#ffffff" "#183691" "#969896" "#a71d5d" "#969896" "#969896" "#795da3" "#969896"])
  631.  '(custom-safe-themes
  632.    (quote
  633.     ("f5568ed375abea716d1bdfae0316d1d179f69972eaccd1f331b3e9863d7e174a" "b0fd04a1b4b614840073a82a53e88fe2abc3d731462d6fde4e541807825af342" "e61752b5a3af12be08e99d076aedadd76052137560b7e684a8be2f8d2958edc3" default)))
  634.  '(evil-want-Y-yank-to-eol nil)
  635.  '(fci-rule-color "#969896")
  636.  '(hl-todo-keyword-faces
  637.    (quote
  638.     (("TODO" . "#dc752f")
  639.      ("NEXT" . "#dc752f")
  640.      ("THEM" . "#2d9574")
  641.      ("PROG" . "#4f97d7")
  642.      ("OKAY" . "#4f97d7")
  643.      ("DONT" . "#f2241f")
  644.      ("FAIL" . "#f2241f")
  645.      ("DONE" . "#86dc2f")
  646.      ("NOTE" . "#b1951d")
  647.      ("KLUDGE" . "#b1951d")
  648.      ("HACK" . "#b1951d")
  649.      ("TEMP" . "#b1951d")
  650.      ("FIXME" . "#dc752f")
  651.      ("XXX+" . "#dc752f")
  652.      ("\\?\\?\\?+" . "#dc752f"))))
  653.  '(jdee-db-active-breakpoint-face-colors (cons "#1B2229" "#fabd2f"))
  654.  '(jdee-db-requested-breakpoint-face-colors (cons "#1B2229" "#8ec07c"))
  655.  '(jdee-db-spec-breakpoint-face-colors (cons "#1B2229" "#555556"))
  656.  '(nrepl-message-colors
  657.    (quote
  658.     ("#183691" "#969896" "#a71d5d" "#969896" "#0086b3" "#795da3" "#a71d5d" "#969896")))
  659.  '(objed-cursor-color "#fb4934")
  660.  '(package-selected-packages
  661.    (quote
  662.     (firecode-theme github-theme treemacs ht pfuture oceanic-theme all-the-icons-dired all-the-icons-gnus all-the-icons-ivy doom mmm-mode cider sesman queue parseedn parseclj a helm-gtags godoctor go-tag go-rename go-impl go-guru go-gen-test go-fill-struct go-eldoc ggtags flycheck-gometalinter flycheck-golangci-lint counsel-gtags counsel swiper ivy company-go go-mode company ws-butler writeroom-mode winum which-key volatile-highlights vi-tilde-fringe uuidgen use-package treemacs-projectile treemacs-evil toc-org symon symbol-overlay string-inflection spaceline-all-the-icons restart-emacs request rainbow-delimiters popwin persp-mode pcre2el password-generator paradox overseer org-plus-contrib org-bullets open-junk-file nameless move-text macrostep lorem-ipsum link-hint indent-guide hungry-delete hl-todo highlight-parentheses highlight-numbers highlight-indentation helm-xref helm-themes helm-swoop helm-purpose helm-projectile helm-mode-manager helm-make helm-flx helm-descbinds helm-ag google-translate golden-ratio font-lock+ flycheck-package flx-ido fill-column-indicator fancy-battery eyebrowse expand-region evil-visualstar evil-visual-mark-mode evil-unimpaired evil-tutor evil-textobj-line evil-surround evil-numbers evil-nerd-commenter evil-mc evil-matchit evil-lisp-state evil-lion evil-indent-plus evil-iedit-state evil-goggles evil-exchange evil-escape evil-ediff evil-cleverparens evil-args evil-anzu eval-sexp-fu elisp-slime-nav editorconfig dumb-jump dotenv-mode doom-modeline diminish devdocs define-word column-enforce-mode clean-aindent-mode centered-cursor-mode auto-highlight-symbol auto-compile aggressive-indent ace-link ace-jump-helm-line)))
  663.  '(pdf-view-midnight-colors (quote ("#b2b2b2" . "#292b2e")))
  664.  '(vc-annotate-background "#b0cde7")
  665.  '(vc-annotate-color-map
  666.    (quote
  667.     ((20 . "#969896")
  668.      (40 . "#183691")
  669.      (60 . "#969896")
  670.      (80 . "#969896")
  671.      (100 . "#969896")
  672.      (120 . "#a71d5d")
  673.      (140 . "#969896")
  674.      (160 . "#969896")
  675.      (180 . "#969896")
  676.      (200 . "#969896")
  677.      (220 . "#63a35c")
  678.      (240 . "#0086b3")
  679.      (260 . "#795da3")
  680.      (280 . "#969896")
  681.      (300 . "#0086b3")
  682.      (320 . "#969896")
  683.      (340 . "#a71d5d")
  684.      (360 . "#969896"))))
  685.  '(vc-annotate-very-old-color "#969896"))
  686. (custom-set-faces
  687.  ;; custom-set-faces was added by Custom.
  688.  ;; If you edit it by hand, you could mess it up, so be careful.
  689.  ;; Your init file should contain only one such instance.
  690.  ;; If there is more than one, they won't work right.
  691.  )
  692. )
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top