diff options
| author | Mountain Man <43313373+MountainMan1312@users.noreply.github.com> | 2023-04-08 20:07:22 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-08 20:07:22 -0400 |
| commit | e274a5f8cbc3cdf6d953e8b37a6c8d79f62266a9 (patch) | |
| tree | 4fabc673a7ad3d50104bdb959fd8f8869ba4622c | |
| parent | Initial commit (diff) | |
| parent | Create `STYLE_GUIDE.md` (diff) | |
| download | mmosmacs-e274a5f8cbc3cdf6d953e8b37a6c8d79f62266a9.tar.gz mmosmacs-e274a5f8cbc3cdf6d953e8b37a6c8d79f62266a9.tar.bz2 mmosmacs-e274a5f8cbc3cdf6d953e8b37a6c8d79f62266a9.zip | |
Merge `initial-plans-docs` branch to `stable` branch
| -rw-r--r-- | CONTRIBUTING.md | 57 | ||||
| -rw-r--r-- | README.md | 43 | ||||
| -rw-r--r-- | STYLE_GUIDE.md | 149 |
3 files changed, 248 insertions, 1 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..d450c7d --- /dev/null +++ b/CONTRIBUTING.md | |||
| @@ -0,0 +1,57 @@ | |||
| 1 | # Contributing to MMOSMacs | ||
| 2 | |||
| 3 | Howdy, and welcome to the MMOSMacs git repository. This document | ||
| 4 | outlines the conventions and standards for the project. | ||
| 5 | |||
| 6 | |||
| 7 | ## This is personal | ||
| 8 | |||
| 9 | Please understand that this is my personal Emacs configuration. MMOSMacs | ||
| 10 | is designed to meet my personal needs. I welcome any and all | ||
| 11 | contributions, and I will do my best to make MMOSMacs accessible to | ||
| 12 | others, but my needs and preferences ultimately take priority. | ||
| 13 | |||
| 14 | All contributors are listed at the end of this document. If you have | ||
| 15 | contributed and your name does not appear here, submit a PR or RFC Issue | ||
| 16 | for it to be added. | ||
| 17 | |||
| 18 | |||
| 19 | ## Code of Conduct | ||
| 20 | |||
| 21 | I will reject all contributions from: | ||
| 22 | - people who abuse other contributors. | ||
| 23 | - people I know to be affiliated with any state agency. | ||
| 24 | |||
| 25 | Furthermore, individual items will be rejected because of: | ||
| 26 | - exceptionally vulgar language. | ||
| 27 | - ignorance or disregard of the `STYLE_GUIDE.md` or Issue/PR templates. | ||
| 28 | |||
| 29 | |||
| 30 | ## How to Contribute | ||
| 31 | |||
| 32 | There are several ways you can contribute. | ||
| 33 | |||
| 34 | The easiest way you can contribute is by taking part in the discussions | ||
| 35 | on the [GitHub Issues page](https://github.com/MountainMan1312/MMOSMacs/Issues). | ||
| 36 | You can comment on topics that already have an existing Issue, or you | ||
| 37 | can submit your own if it does not already exist. Issues can take the | ||
| 38 | form of: | ||
| 39 | - **Feedback**: share your thoughts about MMOSMacs. | ||
| 40 | - **Bug Report**: discusion about a problem with the MMOSMacs code. | ||
| 41 | - **RFC**: discussion about making a change to MMOSMacs. | ||
| 42 | |||
| 43 | Before submitting a new issue, search for existing duplicate issues. If | ||
| 44 | it already exists, comment on the existing Issue instead of making a new | ||
| 45 | one. Duplicate issues will be removed and you will be asked to move your | ||
| 46 | post to the comment section of the existing post. It's not to be rude, | ||
| 47 | it's just for organization's sake. | ||
| 48 | |||
| 49 | Each type of Issue has an Issue Template. The templates can be found in | ||
| 50 | the `.github/ISSUE_TEMPLATE/` directory. Pull reqeusts also have | ||
| 51 | templates which are located in `.github/PULL_REQUEST_TEMPLATE/`. | ||
| 52 | |||
| 53 | To contribute code: | ||
| 54 | 1. Make an RFC or find an existing one | ||
| 55 | 2. Discuss your proposed changes | ||
| 56 | 3. Make your changes | ||
| 57 | 4. Submit a Pull Request | ||
| @@ -1 +1,42 @@ | |||
| 1 | # MMOSMacs \ No newline at end of file | 1 | # MMOSMacs |
| 2 | |||
| 3 | MMOSMacs is the Emacs configuration for MMOS, which is currently just an | ||
| 4 | idea I have for an Emacs-centric Linux distribution. MMOSMacs is the | ||
| 5 | core of my computing experience, and is designed to be a | ||
| 6 | jack-of-all-trades just like me. | ||
| 7 | |||
| 8 | MMOSMacs is currently in the planning phase. | ||
| 9 | |||
| 10 | |||
| 11 | ## Plans | ||
| 12 | |||
| 13 | - Modular non-literate configuration | ||
| 14 | - `straight.el` + `use-package` package management | ||
| 15 | - Emacs as a desktop environment (`EXWM`, `EDNC`) | ||
| 16 | - System & network administration suite | ||
| 17 | - Security & crytography | ||
| 18 | - Software development environment | ||
| 19 | - Communications (Email, RSS, IRC, Matrix, etc.) | ||
| 20 | - Opinionated PKMS and publishing suite | ||
| 21 | - Common desktop applications | ||
| 22 | - Web browser, FTP, Torrent | ||
| 23 | - Multimedia production | ||
| 24 | - OpenSCAD / ImplicitCAD | ||
| 25 | - Finance | ||
| 26 | - Games | ||
| 27 | - Custom modeline & anti-distraction features | ||
| 28 | - Custom theme deisnged to reduce eye-strain | ||
| 29 | - Custom keybinds, menus, & dialogs | ||
| 30 | |||
| 31 | ## Contributing | ||
| 32 | |||
| 33 | This is my personal project. I will do what I can to make it accessible | ||
| 34 | to other people, but ultimately it is crafted to suit my own needs. | ||
| 35 | |||
| 36 | If you want to contribute to MMOSMacs, please read `CONTRIBUTING.md`. If | ||
| 37 | you do not have a copy of this file, it can be found at either: | ||
| 38 | - https://github.com/MountainMan1312/MMOSMacs/blob/stable/README.md | ||
| 39 | - https://raw.githubusercontent.com/MountainMan1312/MMOSMacs/stable/README.md | ||
| 40 | |||
| 41 | Feel free to fork this repository. There is no need to give me credit. | ||
| 42 | It is wrong to claim ownership of knowledge. | ||
diff --git a/STYLE_GUIDE.md b/STYLE_GUIDE.md new file mode 100644 index 0000000..d1e4e6b --- /dev/null +++ b/STYLE_GUIDE.md | |||
| @@ -0,0 +1,149 @@ | |||
| 1 | # STYLE_GUIDE for MMOSMacs | ||
| 2 | |||
| 3 | Much of this Style Guide was taken from | ||
| 4 | [bbatsov/emacs-lisp-style-guide](https://github.com/bbatsov/emacs-lisp-style-guide). | ||
| 5 | |||
| 6 | |||
| 7 | # General guidelines | ||
| 8 | |||
| 9 | - Use spaces for indentation. Do not use tabs anywhere. | ||
| 10 | - Where feasible, avoid making lines longer than 72 chars. | ||
| 11 | - Avoid trailing whitespace. | ||
| 12 | |||
| 13 | |||
| 14 | ## Organization | ||
| 15 | |||
| 16 | Emacs Lisp files should begin with a header. The first line of the | ||
| 17 | header should include the filename, a very brief comment (2-5 words), | ||
| 18 | and the `-*- lexical-binding: t; -*-` thing. The next line(s) should be | ||
| 19 | a more detailed description of the file and it's purpose. | ||
| 20 | |||
| 21 | ```elisp | ||
| 22 | ;;; -*- lexical-binding: t; -*- | ||
| 23 | ;;; init.el | ||
| 24 | ;; | ||
| 25 | ;; Main config file for MMOSMacs; the glue that binds the modules | ||
| 26 | ;; together. Provides package management, performance tweaks, and | ||
| 27 | ;; integrates all the other MMOSMacs modules. | ||
| 28 | ``` | ||
| 29 | |||
| 30 | All Emacs Lisp files are organized into Sections and Subsections using | ||
| 31 | comment decorations. Section titles begin with `;;;`, are ALL CAPS, and | ||
| 32 | their decorations extend up to 72 chars. Subsections begin with `;;` | ||
| 33 | and their decorations extend up to 36 chars. Titles should be underlined | ||
| 34 | with dashes on the proceeding line. Explanatory comments go below the | ||
| 35 | title underline, and an additional 36-or-72-char line goes at the bottom | ||
| 36 | of the header. | ||
| 37 | |||
| 38 | Each subsection should have 2 blank lines between the top line of the | ||
| 39 | header and the bottom line of code from the previous subsection. Only | ||
| 40 | one line goes between the Section header and the first Subsection, as | ||
| 41 | well as between portions of code within the same subsection. 4 lines go | ||
| 42 | between a new Section header and the previous bit of code. | ||
| 43 | |||
| 44 | ```elisp | ||
| 45 | ;; integrates all the other MMOSMacs modules. | ||
| 46 | |||
| 47 | |||
| 48 | ;; --------------------------------------------------------------------- | ||
| 49 | ;;; FIRST SECTION TITLE | ||
| 50 | ;; -------------------- | ||
| 51 | ;; Comments about the purpose of the section go here. | ||
| 52 | ;; It should be concise. Don't go into too much detail. | ||
| 53 | ;; --------------------------------------------------------------------- | ||
| 54 | |||
| 55 | ;; --------------------------------- | ||
| 56 | ;; Subsection Title | ||
| 57 | ;; ---------------- | ||
| 58 | ;; Subsection explanatory text goes | ||
| 59 | ;; here. Limit the line length to 36 | ||
| 60 | ;; chars to maintain the visual | ||
| 61 | ;; "togetherness" of the header. | ||
| 62 | ;; | ||
| 63 | ;; Notice only 1 space between the | ||
| 64 | ;; Section header and the top of the | ||
| 65 | ;; first Subsection header. | ||
| 66 | ;; --------------------------------- | ||
| 67 | |||
| 68 | ;; `something` is a package I bet | ||
| 69 | (use-package something | ||
| 70 | :straight t | ||
| 71 | :init | ||
| 72 | (setq some-crap nil)) | ||
| 73 | |||
| 74 | ;; `something-else` is a little less | ||
| 75 | ;; likely to be a package | ||
| 76 | (use-package something-else | ||
| 77 | :straight t) | ||
| 78 | |||
| 79 | |||
| 80 | ;; --------------------------------- | ||
| 81 | ;; Subsection Title | ||
| 82 | ;; ---------------- | ||
| 83 | ;; Notice the 2 lines separating | ||
| 84 | ;; each Subsection. | ||
| 85 | ;; --------------------------------- | ||
| 86 | |||
| 87 | ;; I really don't know what to write | ||
| 88 | ;; in these example comments. | ||
| 89 | (use-package some-other-thing | ||
| 90 | :straight | ||
| 91 | :init | ||
| 92 | (other-thing-mode)) | ||
| 93 | |||
| 94 | |||
| 95 | |||
| 96 | |||
| 97 | ;; --------------------------------------------------------------------- | ||
| 98 | ;;; SECOND SECTION TITLE | ||
| 99 | ;; --------------------- | ||
| 100 | ;; Notice the 4 empty lines above this section. | ||
| 101 | ;; This provides visual separation; easier on the eyes. | ||
| 102 | ;; --------------------------------------------------------------------- | ||
| 103 | ``` | ||
| 104 | |||
| 105 | |||
| 106 | ## Comments & Annotations | ||
| 107 | |||
| 108 | - Write heading comments with 3 semicolons, and regular comments with 2. | ||
| 109 | - Write margin comments with 1 semicolon. | ||
| 110 | - Leave 1 space between the semicolons and the comment text. | ||
| 111 | - Comments longer than 1 word are capitalized and use punctuation. | ||
| 112 | |||
| 113 | ```elisp | ||
| 114 | ;;; This is a heading comment | ||
| 115 | ;; This is a regular comment with more words and stuff. | ||
| 116 | ;; Something something something. | ||
| 117 | (defun foo (bar) | ||
| 118 | (something something | ||
| 119 | something-else)) ; for some other reason | ||
| 120 | ``` | ||
| 121 | |||
| 122 | |||
| 123 | ## Docstrings | ||
| 124 | |||
| 125 | - Begin docstrings with a terse, complete sentence. Use imperative | ||
| 126 | language (e.g. "Verify" instead of "Verifies") | ||
| 127 | - When a function takes arguments, mention what the arguments do, | ||
| 128 | whether they are optional or required, etc. Describe the arguments in | ||
| 129 | UPPERCASE, and describe them in the order they are used in the function. | ||
| 130 | - Do not indent subsequent lines of a docstring. It looks nice in source | ||
| 131 | code but looks bizarre when viewed in Emacs. | ||
| 132 | |||
| 133 | ```elisp | ||
| 134 | ;; good | ||
| 135 | (defun goto-line (line &optional buffer) | ||
| 136 | "Go to LINE, counting from line 1 at beginning of buffer. | ||
| 137 | If called interactively, a numeric prefix argument specifies | ||
| 138 | LINE; without a numeric prefix argument, read LINE from the | ||
| 139 | minibuffer..." | ||
| 140 | ...) | ||
| 141 | |||
| 142 | ;; bad | ||
| 143 | (defun goto-line (line &optional buffer) | ||
| 144 | "Go to LINE, counting from line 1 at beginning of buffer. | ||
| 145 | If called interactively, a numeric prefix argument specifies | ||
| 146 | LINE; without a numeric prefix argument, read LINE from the | ||
| 147 | minibuffer..." | ||
| 148 | ...) | ||
| 149 | ``` | ||