Thanks to visit codestin.com
Credit goes to github.com

Skip to content

jcs-emacs/jcs-emacs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

License Emacs Release Tag CI

Windows macOS Linux

Table of Contents

jcs-emacs

Consistent Emacs configuration for all platforms.

This is Jen-Chieh Shen's emacs configuration. This configuration started from Casey Muratori's Emacs configuration. It has been repeatedly utilized and modified since 2015 and is now very different to his configuration.

I wouldn't claim this is the best Emacs config, but this is the best config to myself. If you wish to learn Emacs, this could be a good start, because this configuration has been rewritten basically from scratch. Hopefully, this config will help someone who is new or struggle to Emacs. This configuration should work on most OSs, indicates Windows, macOS, and Linux.

Emacs itself supports multiple programming languages. I managed all the programming languages I personally used. I dabble in numerous technologies, incorporate hardware, firmware and software. Here is the list of programming languages I know and are extended from this configuration.

  • ActionScript 2.0 or 3.0 / Ada / Agda / AppleScript / Assembly Language
  • BASIC / Batchfile
  • C / C++ / C# / Clojure / CMake / COBOL / CSS
  • Dart / Dockerfile
  • Elixir / Elm / Emacs Lisp / Erlang
  • F# / Fountain
  • GLSL / Go / GDScript / Groovy
  • Haskell / Haxe / HTML
  • INI
  • Java / JavaScript / JSON / JSX
  • Kotlin
  • LESS / Lisp / Lua
  • Makefile / Markdown
  • Nix
  • Object Pascal (Delphi) / Objective-C
  • Pascal / Perl / PHP / PowerShell / Properties / Python
  • R / Ruby / Rust
  • Sass / Scala / SCSS / Shader / Shell script / SQL / Swift
  • TOML / TSX / TypeScript
  • Verilog / Vimscript / Vue
  • XML
  • YAML

This configuration polished and goes toward to the modern text editor, or even better, it goes beyond modern IDE. e.g. Atom, Brackets, Sublime Text 2 or 3, Visual Studio Code, etc.

Philosophy

I have experienced many different kinds of IDEs and text editors. But I’ve had a hard time finding the best tool to use. I’ve jumped from one working field to another trying to find something that suits my needs. So instead of struggling with the tool itself, I chose Emacs and configured the entire thing from scratch, to suit my needs.

Here are a few goals that I want this config to accomplished.

  • Having the same set of key bindings across different IDEs and text editors as many as possible.
  • Having the same font and theme across different OSs and environments.
  • Automating trivial or redundant tasks.
  • Improve user experiences approach to modern text editor or IDE.
  • Make compatible to most features work inside terminal as well.

Having these implementations makes my life easier, and having a genuinely portable workspace, which is great because it lets me work on different machine efficiently, without having to get used to an new IDE.

πŸ“° News

Here is the list of few important and recent changes to this configuration.

  • 8.0.0 - Move everything to .emacs.d. (#32)
  • 7.1.0 - Replace quelpa with github-elpa.
  • 7.0.0 - Switch from quickhelp to box for company frontend.
  • 6.5.0 - Add pinned archive feature to package module.
  • 6.4.2 - You can now resolve package dependency graph while deleting package.
  • 6.4.1 - Start with tree-sitter support.
  • 6.4.0 - Switched from projectile to built-in project for project management.
  • 6.3.1 - Replaced docstring module to external docstr package.
  • 6.2.5 - Use recipes folder instead to specify manually installed packages in the configuration.
  • 6.2.4 - Replaced ag silver searcher to searcher.

πŸ’Ύ Installation

To install, clone this repo to ~/.emacs.d, i.e. ensure that the init.el contained in this repo ends up at ~/.emacs.d/init.el:

git clone https://github.com/jcs-emacs/jcs-emacs ~/.emacs.d

Then startup Emacs; it will automatically installs all necessary packages due to this configuration.

❗❗ [ATTENTION] ❗❗ -- MAKE SURE YOU INSTALLED THE CORRECT VERSION OF EMACS!

πŸ•’ Startup Time

The average startup time for this configuration is around 15 to 25 seconds. You can use command emacs-init-time to check the startup time on your machine. Not quite sure what causes that much of performance, hopefully, I'm able to lower the startup time down to 5 to 15 seconds.

Edit 1: After version 5.3.2, the average startup time is around 5 to 15 seconds. Solved this issue by removing unnecessary require keyword load file and use :defer keyword with use-package package to delay some packages load time.

πŸ“ P.S. Here is a great article about Speeding Up Emacs written by Anurag Peshne.

Edit 2: If you compiled the source code then the startup time can lower down more from 0.5 to 1.5 seconds.

Edit 3: Using esup package to test and optimize the configuration. Call package-refresh-contents only when package installation is needed. By doing thing, lower the startup time from around 4 to 8 seconds.

πŸ“ P.S. Some good hints from one StackExchange question, What can I do to speed up my start-up? answered by Jordon Biondo.

πŸ“ P.S. The above cases are tested on Windows. Other OS that are not Windows should start up under a second.

πŸ† Features

Highlight

Here is the list of the major highlights to this configuration. Hope you would like my taste!

  • Out of the box - Out of the box anywhere.
  • Cross Platform - Work on all operating system including terminal.
  • Fast Startup - Lazy loading for all unnecessary packages on startup.
  • Old-Fashioned - Doesn't use any beatiful GUI because it may not work in terminal.
  • Multiple Languages - Support multiple programming languages.
  • Consistent - Having the same coding experience in different major mode.
  • Easy to use - Design close to other modern text editors. Shouldn't spend you too much time.
  • Dual Windows - Design to people who like multiple windows opened simultaneously.
  • Keyboard Focused - You can do everything by using keyboard and mouse are just optional.

Details

This is the list of features that are built-in to this configuration. These features are heavily base on my personal habits, and so these could be very tiny things. But I believed detials make things better and make life smoother.

πŸ“ Package Archives

A list of package archives that this configuration uses.

  • ELPA - Emacs Lisp Package Archive
  • MELPA - Milkypostman’s Emacs Lisp Package Archive
  • elpa (jcs) - Emacs Lisp Package Archive for this configuration

πŸ“ P.S. Here is a good talk comparing all package archives from a StackExchange question, What are the practical differences between the various Emacs Package Repositories? answered by Tikhon Jelvis.

πŸ† Powered by

Here is the list of all packages that powered and make this configuration works. Thanks to all the package maintainers; this configuration cannot be made without them, and if you wish to support them you can go to this elisp-maintainers repo/site and search for the maintainer you want to support. There should be some kind of methods that you could support the maintainer you want.

Functionalities

Write your own customization

You are able to customize the configuration by editing the file locate at ~/.emacs.d/site-lisp/jcs-config.el. You should put all your own customize code there, then other than that are the core files.

🎍 Supported Emacs versions

The config should run on Emacs 27.1 or higher, but I will recommend to always run on the latest Emacs version available on your machine. The ultimate goal is to design to have each version of config can run on their each according Emacs version base on the version what I'm currently running on my present machine. For each version record, you can check the version_record file at the root of the project directory.

❓ FAQ

Here is the list of Frequently Asked Questions.

Contribute

PRs Welcome Elisp styleguide Donate on paypal

If you would like to contribute to this project, you may either clone and make pull requests to this repository. Or you can clone the project and establish your own branch of this tool. Any methods are welcome!