Add JS support
This commit is contained in:
parent
ddea45a6e8
commit
2d3ca06b73
4 changed files with 96 additions and 6 deletions
41
.profile
Normal file
41
.profile
Normal file
|
@ -0,0 +1,41 @@
|
|||
# Sample .profile for SuSE Linux
|
||||
# rewritten by Christian Steinruecken <cstein@suse.de>
|
||||
#
|
||||
# This file is read each time a login shell is started.
|
||||
# All other interactive shells will only read .bashrc; this is particularly
|
||||
# important for language settings, see below.
|
||||
|
||||
test -z "$PROFILEREAD" && . /etc/profile || true
|
||||
|
||||
# Most applications support several languages for their output.
|
||||
# To make use of this feature, simply uncomment one of the lines below or
|
||||
# add your own one (see /usr/share/locale/locale.alias for more codes)
|
||||
# This overwrites the system default set in /etc/sysconfig/language
|
||||
# in the variable RC_LANG.
|
||||
#
|
||||
#export LANG=de_DE.UTF-8 # uncomment this line for German output
|
||||
#export LANG=fr_FR.UTF-8 # uncomment this line for French output
|
||||
#export LANG=es_ES.UTF-8 # uncomment this line for Spanish output
|
||||
export LANG=en_US.UTF-8
|
||||
export LC_ALL=en_US.UTF-8
|
||||
# Some people don't like fortune. If you uncomment the following lines,
|
||||
# you will have a fortune each time you log in ;-)
|
||||
|
||||
#if [ -x /usr/bin/fortune ] ; then
|
||||
# echo
|
||||
# /usr/bin/fortune
|
||||
# echo
|
||||
#fi
|
||||
|
||||
# set PATH so it includes user's private bin if it exists
|
||||
if [ -d "$HOME/bin" ] ; then
|
||||
PATH="$HOME/bin:$PATH"
|
||||
fi
|
||||
|
||||
# set PATH so it includes user's private bin if it exists
|
||||
if [ -d "$HOME/.local/bin" ] ; then
|
||||
PATH="$HOME/.local/bin:$PATH"
|
||||
fi
|
||||
|
||||
export PATH="$HOME/.cargo/bin:$PATH"
|
||||
export PATH="$HOME/.npm-packages/bin:$PATH"
|
|
@ -18,24 +18,30 @@
|
|||
(fullscreen . maximized)
|
||||
(alpha . 98))))
|
||||
'(delete-selection-mode nil)
|
||||
'(elpy-modules
|
||||
(quote
|
||||
(elpy-module-company elpy-module-eldoc elpy-module-flymake elpy-module-folding elpy-module-pyvenv elpy-module-yasnippet elpy-module-django elpy-module-sane-defaults)))
|
||||
'(fci-rule-color "#4C566A")
|
||||
'(global-hl-line-mode t)
|
||||
'(indent-tabs-mode nil)
|
||||
'(inhibit-startup-buffer-menu t)
|
||||
'(initial-buffer-choice "~/Documents/Journal/notes.org")
|
||||
'(initial-buffer-choice "~/Documents/journal/notes.org")
|
||||
'(menu-bar-mode nil)
|
||||
'(org-adapt-indentation t)
|
||||
'(org-agenda-files (quote ("~/Documents/Journal")))
|
||||
'(org-agenda-files (quote ("~/Documents/journal")))
|
||||
'(org-babel-python-command "python3")
|
||||
'(org-default-notes-file "~/Documents/Journal/notes.org")
|
||||
'(org-default-notes-file "~/Documents/journal/notes.org")
|
||||
'(org-html-htmlize-output-type nil)
|
||||
'(org-modules
|
||||
(quote
|
||||
(ol-bbdb ol-bibtex ol-docview ol-eww ol-gnus ol-info ol-irc ol-mhe ol-rmail org-tempo ol-w3m orgtbl-sqlinsert org-toc)))
|
||||
(ol-bbdb ol-docview ol-eww ol-gnus ol-info ol-irc ol-mhe ol-rmail org-tempo ol-w3m orgtbl-sqlinsert)))
|
||||
'(org-plantuml-jar-path "~/.local/bin/plantuml.jar")
|
||||
'(package-enable-at-startup t)
|
||||
'(package-selected-packages
|
||||
(quote
|
||||
(lua-mode nordless-theme use-package elpy colorless-themes nord-theme org toc-org ox-reveal ace-window htmlize ivy magit)))
|
||||
(web-mode js2-mode slime flymake-racket racket-mode yaml-mode lua-mode nordless-theme use-package elpy colorless-themes nord-theme org toc-org ox-reveal ace-window htmlize ivy magit)))
|
||||
'(scroll-bar-mode nil)
|
||||
'(tool-bar-mode nil)
|
||||
'(tramp-default-method "ssh"))
|
||||
(custom-set-faces
|
||||
;; custom-set-faces was added by Custom.
|
||||
|
|
43
init.el
43
init.el
|
@ -85,6 +85,49 @@
|
|||
:init
|
||||
(elpy-enable))
|
||||
|
||||
(use-package js2-mode
|
||||
:ensure t
|
||||
:interpreter (("node" . js2-mode))
|
||||
:bind (:map js2-mode-map ("C-c C-p" . js2-print-json-path))
|
||||
:mode "\\.\\(js\\|json\\)$"
|
||||
:config
|
||||
(add-hook 'js-mode-hook 'js2-minor-mode)
|
||||
(setq js2-basic-offset 2
|
||||
js2-highlight-level 3
|
||||
js2-mode-show-parse-errors nil
|
||||
js2-mode-show-strict-warnings nil))
|
||||
|
||||
(use-package web-mode
|
||||
:ensure t
|
||||
:mode "\\.html?\\'"
|
||||
:init
|
||||
(dolist (hook '(emmet-mode ac-emmet-html-setup ac-emmet-css-setup))
|
||||
(add-hook 'web-mode-hook hook))
|
||||
:config
|
||||
(setq web-mode-markup-indent-offset 2
|
||||
web-mode-css-indent-offset 2
|
||||
web-mode-code-indent-offset 2
|
||||
web-mode-enable-auto-pairing nil
|
||||
web-mode-enable-auto-closing t
|
||||
web-mode-enable-current-element-highlight t
|
||||
web-mode-enable-current-column-highlight t
|
||||
web-mode-ac-sources-alist
|
||||
'(("css" . (ac-source-css-property ac-source-emmet-css-snippets))
|
||||
("html" . (ac-source-emmet-html-aliases
|
||||
ac-source-emmet-html-snippets))))
|
||||
(add-hook 'web-mode-before-auto-complete-hooks
|
||||
'(lambda ()
|
||||
(let ((web-mode-cur-language (web-mode-language-at-pos)))
|
||||
(if (string= web-mode-cur-language "css")
|
||||
(setq emmet-use-css-transform t)
|
||||
(setq emmet-use-css-transform nil)))))
|
||||
(defun zakame/sp-web-mode-code-context-p (id action context)
|
||||
"Set smartparens context when in web-mode."
|
||||
(and (eq action 'insert)
|
||||
(not (or (get-text-property (point) 'part-side)
|
||||
(get-text-property (point) 'block-side)))))
|
||||
(sp-local-pair 'web-mode "<" nil :when '(zakame/sp-web-mode-code-context-p)))
|
||||
|
||||
;; ORG_MODE SETTINGS
|
||||
(setq org-agenda-dim-blocked-tasks nil
|
||||
org-agenda-inhibit-startup nil
|
||||
|
|
|
@ -260,7 +260,7 @@ sync_to_monitor yes
|
|||
|
||||
#: Terminal bell {{{
|
||||
|
||||
enable_audio_bell yes
|
||||
enable_audio_bell no
|
||||
|
||||
#: Enable/disable the audio bell. Useful in environments that require
|
||||
#: silence.
|
||||
|
|
Loading…
Add table
Reference in a new issue