### Install Python LSP Server (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/README.org Installs the python-lsp-server package, which is required for the 'pylsp' backend. It also shows how to install with all optional dependencies. ```sh pip install python-lsp-server ``` ```sh pip install 'python-lsp-server[all]' ``` -------------------------------- ### Install and Manage Dotfile Source: https://github.com/syl20bnr/spacemacs/blob/develop/doc/QUICK_START.org Commands to install the initial .spacemacs file and open it for editing. ```elisp SPC SPC dotspacemacs/install RET SPC f e d ``` -------------------------------- ### Install Go Binary Dependencies Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/go/README.org Installs essential Go development tools and linters via the command line. ```sh GO111MODULE=on CGO_ENABLED=0 go install -v -trimpath -ldflags '-s -w' github.com/golangci/golangci-lint/v2/cmd/golangci-lint@latest go install golang.org/x/tools/cmd/godoc@latest go install golang.org/x/tools/cmd/goimports@latest go install golang.org/x/tools/cmd/gorename@latest go install golang.org/x/tools/cmd/guru@latest go install github.com/cweill/gotests/...@latest go install github.com/davidrjenni/reftools/cmd/fillstruct@latest go install github.com/fatih/gomodifytags@latest go install github.com/godoctor/godoctor@latest go install github.com/haya14busa/gopkgs/cmd/gopkgs@latest go install github.com/josharian/impl@latest go install github.com/rogpeppe/godef@latest ``` -------------------------------- ### Install Prerequisites via NPM Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/typescript/README.org Install necessary tools like eslint, tslint, or typescript-formatter globally or locally. ```shell npm install eslint npm install -g typescript tslint npm install -g typescript-formatter ``` -------------------------------- ### Install LSP Server for CMake Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/cmake/README.org Command to install the required language server for the LSP backend. ```sh pip install cmake-language-server ``` -------------------------------- ### Install SCSS Lint Tools (Command Line) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/html/README.org Installs the necessary SCSS-Lint tools from GitHub, which are required for SCSS linting with the HTML layer. Ensure you have Ruby and gem installed. ```command-line gem install scss_lint_reporter_checkstyle gem install scss_lint ``` -------------------------------- ### Verify Scalastyle Installation Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/scala/README.org Command to verify that the Scalastyle executable is correctly installed and available in the system PATH. ```bash $ scalastyle scalastyle 0.8.0 Usage: scalastyle [options] ... ``` -------------------------------- ### Install MCP Filesystem Server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+web-services/github-copilot/README.org Installs the Model Context Protocol filesystem server via npm, which allows the AI to interact with the local filesystem. ```shell npm install -g @modelcontextprotocol/server-filesystem ``` -------------------------------- ### Install ESLint and Formatters Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+frameworks/react/README.org Commands to install necessary global npm packages for syntax checking and code formatting in the React layer. ```sh npm install -g eslint babel-eslint eslint-plugin-react npm install -g js-beautify prettier ``` -------------------------------- ### Install Go Language Server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/go/README.org Installs the gopls language server required for the LSP backend. This command uses Go modules to fetch and install the latest version of the server. ```sh GO111MODULE=on go install golang.org/x/tools/gopls@latest ``` -------------------------------- ### Install rnix-lsp via Nix Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+os/nixos/README.org Installs the rnix-lsp language server from the nix-community repository using the nix-env command line tool. ```shell nix-env -i -f https://github.com/nix-community/rnix-lsp/archive/master.tar.gz ``` -------------------------------- ### Install libtool on Ubuntu Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/shell/README.org Installs the libtool-bin package on Ubuntu, required for building certain Emacs dynamic modules. ```shell sudo apt install libtool-bin ``` -------------------------------- ### Install Poppler Utilities for Instruction Lookup Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/asm/README.org Install the poppler-utils package to provide the pdftotext tool required for indexing instruction documentation PDFs. ```sh sudo apt-get install poppler-utils ``` -------------------------------- ### Install LSP server dependencies Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/elm/README.org Installs the necessary language server and analysis tools required for the LSP backend to function correctly. ```sh npm install -g elm-analyse @elm-tooling/elm-language-server ``` -------------------------------- ### Install shfmt formatter Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/shell-scripts/README.org Installs the shfmt tool using Go, which is required for automatic shell script formatting within the layer. ```sh go install mvdan.cc/sh/v3/cmd/shfmt@latest ``` -------------------------------- ### Install Vim Language Server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/vimscript/README.org Installs the required vim-language-server globally via npm to enable LSP functionality for the Vimscript layer. ```sh npm install -g vim-language-server ``` -------------------------------- ### Install js-beautify Globally Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/web-beautify/README.org This command installs the js-beautify tool globally using npm. This is a prerequisite for the web-beautify layer to function correctly. ```sh npm install -g js-beautify ``` -------------------------------- ### Install Nim LSP server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/nim/README.org Installs the nimlsp server via the nimble package manager, which is required for the LSP backend to function correctly. ```sh nimble install nimlsp ``` -------------------------------- ### Install Metals Language Server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/scala/README.org Uses coursier to bootstrap and install the Metals language server executable, which is required for LSP functionality in the Scala layer. ```bash ./coursier bootstrap \ --java-opt -Xss4m \ --java-opt -Xms100m \ --java-opt -Dmetals.client=emacs \ org.scalameta:metals_2.12:0.9.8 \ -r bintray:scalacenter/releases \ -r sonatype:snapshots \ -o /usr/local/bin/metals-emacs -f ``` -------------------------------- ### Install vmd for Live Preview Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/markdown/README.org Command to install the vmd executable globally using npm. This is required for GitHub-flavored live preview when configured in Spacemacs. ```shell npm install -g vmd ``` -------------------------------- ### Configure and Install Themes Source: https://github.com/syl20bnr/spacemacs/blob/develop/doc/DOCUMENTATION.org Shows how to set default themes, fetch themes from external repositories, and handle package-specific theme configurations in dotspacemacs. ```emacs-lisp (setq-default dotspacemacs-themes '(spacemacs-light leuven zenburn)) (setq-default dotspacemacs-themes '(spacemacs-light leuven (zenburn :location (recipe :fetcher github :repo "bbatsov/zenburn-emacs")) )) (setq-default dotspacemacs-themes '((humanoid-light :package humanoid-themes) spacemacs-dark)) ``` -------------------------------- ### Install PyCscope via Pip Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tags/cscope/README.org Installs the PyCscope tool using the Python package installer. ```sh pip install pycscope ``` -------------------------------- ### Install Autoflake (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/README.org Install autoflake, a tool to remove unused imports from Python code. This is a command-line installation using pip. ```sh pip install autoflake ``` -------------------------------- ### Install Anaconda Dependencies (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/README.org Installs or upgrades the necessary dependencies for anaconda-mode if manual installation is required. This is a common fix for blocking process output errors. ```sh pip install --upgrade "jedi>=0.13.0" "json-rpc>=1.8.1" "service_factory>=0.1.5" ``` -------------------------------- ### Initialize MCP Hub Configuration Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+web-services/github-copilot/README.org Example structure for configuring MCP servers within the dotspacemacs/user-config function to ensure they load after the mcp-hub package. ```elisp (defun dotspacemacs/user-config () ;; ... (with-eval-after-load 'mcp-hub ;; Configure servers here )) ``` -------------------------------- ### Install Agda via Cabal Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/agda/README.org Installs the Agda compiler and its dependencies using the Cabal package manager. This command assumes Cabal is already installed on the system. ```sh cabal install alex happy "cpphs < 1.19" agda ``` -------------------------------- ### Install Legacy Go Dependencies Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/go/README.org Installs the necessary binaries for auto-completion when using the deprecated go-mode backend. These tools provide code suggestions and documentation lookups. ```sh go install github.com/mdempsky/gocode@latest go install github.com/zmb3/gogetdoc@latest ``` -------------------------------- ### Install Wakatime Program using Pip Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+web-services/wakatime/README.org Installs the Wakatime command-line program using pip. This is a prerequisite for the Spacemacs Wakatime layer. It handles both standard and sudo installations. ```sh pip install wakatime ``` ```sh sudo pip install wakatime ``` -------------------------------- ### Install Jupyter Notebook (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/ipython-notebook/README.org This command installs the Jupyter Notebook package using pip, which is a dependency for the IPython Notebook layer in Spacemacs. Ensure you have Python and pip installed. ```shell pip install jupyter ``` -------------------------------- ### Install Project Dependencies Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/elixir/README.org This shell command is used to fetch and install project dependencies, including newly added ones like Credo or Dogma, after updating the mix.exs file. ```shell $ mix deps.get ``` -------------------------------- ### Run Emacs with Debugging Flags (Text) Source: https://github.com/syl20bnr/spacemacs/wiki/Debugging.org These commands demonstrate how to launch Emacs with specific flags to aid in debugging. '--debug-init' enables debugging for initialization errors, and '--timed-requires' helps identify slow-loading packages. ```text emacs --debug-init ``` ```text emacs --debug-init --timed-requires ``` -------------------------------- ### Project-Specific Haskell Backend Configuration with .dir-locals.el Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/haskell/README.org This example demonstrates how to configure the Haskell completion backend for a specific project using a directory local variables file (`.dir-locals.el`). It sets the backend to 'lsp' for haskell-mode. ```elisp ;;; Directory Local Variables ;;; For more information see (info "(emacs) Directory Variables") ((haskell-mode (haskell-completion-backend . lsp))) ``` -------------------------------- ### Install SQL Formatting Binary Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/sql/README.org Downloads and extracts the sqlfmt binary for Linux to enable SQL code formatting. ```sh wget -q -O - https://github.com/mjibson/sqlfmt/releases/latest/download/sqlfmt_0.4.0_linux_amd64.tar.gz | tar -xpvzf - --directory "${installdir}/bin" ``` -------------------------------- ### Verify Ctags Installation Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tags/gtags/README.org Checks if the installed ctags version is the Exuberant version required by the Gtags layer. ```sh ctags --version | grep Exuberant ``` -------------------------------- ### Install GNU Global from Source Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tags/gtags/README.org Provides commands to download, configure, build, and install GNU Global from its source tarball. This method is recommended for obtaining the latest features and ensuring compatibility. ```sh tar xvf global-.tar.gz cd global- ./configure CC=gcc-8 --with-exuberant-ctags=/usr/bin/ctags make sudo make install ``` ```sh tar xvf global-.tar.gz cd global- ./configure --with-exuberant-ctags=/usr/bin/ctags make sudo make install ``` -------------------------------- ### Install libvterm on macOS Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/shell/README.org Installs the libvterm library on macOS using Homebrew for enhanced terminal emulation support. ```shell brew install libvterm ``` -------------------------------- ### Download and Apply PR Patches with Git Source: https://github.com/syl20bnr/spacemacs/wiki/Collaborator-PR-Guide This example shows how to download a pull request as a patch file using `wget` and then apply it to the current branch using `git am`. This method serves as a fallback for slower Forge operations or when encountering bugs, allowing manual application of PR changes. ```Shell wget https://github.com/syl20bnr/spacemacs/pull/10684.patch git am 10684.patch ``` -------------------------------- ### Install CMake on Ubuntu Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/shell/README.org Installs the CMake build tool on Ubuntu systems using the apt package manager. ```shell sudo apt install cmake ``` -------------------------------- ### Install Copilot Language Server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+web-services/github-copilot/README.org Methods to install the required GitHub Copilot language server, either via global npm or directly within the Emacs environment. ```shell npm install -g @github/copilot-language-server ``` ```elisp SPC SPC copilot-install-server ``` -------------------------------- ### Install CMake on macOS Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/shell/README.org Installs the CMake build tool on macOS using Homebrew, which is a prerequisite for compiling vterm. ```shell brew install cmake ``` -------------------------------- ### Configure Packages with use-package Source: https://github.com/syl20bnr/spacemacs/blob/develop/doc/VIMUSERS.org Demonstrates how to use the use-package macro for lazy-loading, initialization, and post-load configuration of Emacs packages. ```emacs-lisp (use-package package-name :defer t) (use-package package-name :defer t :init (setq variable1 t variable2 nil) (defun foo () (message "%s" "Hello, World!")) :config (function-defined-when-package-loads)) ``` -------------------------------- ### Install Flake8 for Syntax Checking (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/README.org Installs the flake8 package, which is used by Spacemacs for Python syntax checking. ```sh pip install flake8 ``` -------------------------------- ### Deferred Package Loading with use-package Source: https://github.com/syl20bnr/spacemacs/blob/develop/doc/LAYERS.org This use-package example demonstrates how to defer the loading of a package using the ':defer t' keyword. This leverages Emacs' auto-loading mechanisms, effectively making the package load only when its functions or modes are actually used, thus improving startup performance. ```emacs-lisp (use-package helm :defer t) ``` -------------------------------- ### Manage Pylookup Database via CLI Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/local/pylookup/README.md These commands demonstrate how to index documentation sources into the Pylookup database. It covers downloading, updating, and appending local or remote documentation sources. ```bash # Download and construct database make download # Index a single source ./pylookup.py -u http://docs.python.org # Index multiple sources ./pylookup.py -u http://docs.python.org -u ~/doc/python2.7 # Append a local source to an existing database ./pylookup.py -a -u ~/doc/python ``` -------------------------------- ### Install Python-Markdown Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/markdown/README.org Command to install the Python-Markdown package using pip. This is a dependency for certain Markdown processing functionalities. ```shell pip install --user Markdown ``` -------------------------------- ### Install Cscope via Package Manager Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tags/cscope/README.org Installs the Cscope tool on Debian-based systems using the apt package manager. ```sh sudo apt-get install cscope ``` -------------------------------- ### List Installed NPM Dependencies in Spacemacs Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/typescript/README.org This keybinding in Spacemacs' NPM mode displays a list of the installed project dependencies. ```emacs-lisp SPC m n l ``` -------------------------------- ### Configure Java Backend in Spacemacs Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/java/README.org Demonstrates how to set the preferred Java backend within the Spacemacs configuration file or via directory-local variables for project-specific settings. ```elisp (java :variables java-backend 'meghanada) ``` ```elisp ;;; Directory Local Variables ((java-mode (java-backend . lsp))) ``` -------------------------------- ### Install Pyright Language Server (Shell) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/python/README.org Provides commands to install the Microsoft Pyright language server using different package managers: pip, yarn, or npm. ```sh # via pip pip install pyright ``` ```sh # or via yarn yarn global add pyright ``` ```sh # or via npm npm install -g pyright ``` -------------------------------- ### Install Solargraph for LSP Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/ruby/README.org Installs the solargraph gem globally to enable Language Server Protocol support for Ruby in Spacemacs. ```sh gem install solargraph ``` -------------------------------- ### Install Language Server Dependencies Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/javascript/README.org Shell commands to install necessary language server packages for TypeScript and Flow support. ```sh npm i -g typescript typescript-language-server ``` ```sh npm i -g typescript javascript-typescript-langserver ``` ```sh npm i -g flow-bin ``` -------------------------------- ### Execute CFEngine3 SRC Block (CFEngine3) Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+tools/cfengine/README.org This snippet shows a basic CFEngine3 bundle agent that prints 'Hello World!' to the reports. It is intended to be executed within an org-mode file using the ob-cfengine3 package. ```cfengine3 bundle agent main { reports: "Hello World!"; } ``` -------------------------------- ### Install SQL Linting Dependency Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/sql/README.org Installs the sqlint gem required for SQL syntax checking in the Spacemacs SQL layer. ```ruby gem install sqlint ``` -------------------------------- ### Install bash language server Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/shell-scripts/README.org Installs the bash-language-server globally via npm to enable LSP support for shell scripts. ```sh npm i -g bash-language-server ``` -------------------------------- ### Configure Go Documentation Backend Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/go/README.org Sets the documentation lookup function to use gogetdoc instead of the default gocode. ```emacs-lisp (go :variables godoc-at-point-function 'godoc-gogetdoc) ``` -------------------------------- ### Install PHP Language Server via Composer Source: https://github.com/syl20bnr/spacemacs/blob/develop/layers/+lang/php/README.org Instructions to install the php-language-server using Composer. This is an alternative LSP server that runs on PHP, unlike intelephense which is Node.js based. ```sh composer require felixfbecker/language-server composer run-script --working-dir=vendor/felixfbecker/language-server parse-stubs ```