VS Code - Bryan's [[linked]] approach in DevOps markdown doc at work #119
-
Hi @tallguyjenks, on Twitter you mentioned your work team uses VS Code for [[linked]] markdown documentation. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
@fakoh We use a LOT of extensions, I also have a custom bash profile in the repo that gets loaded by our settings.json for git aliases and other things. .vscode/.bashrc# Friendly aliases to use with git in the shell for those that like simplicity
# Allow vim mode editing on the CLI (<ESC> to enter normal mode)
set -o vi
alias v="vim"
alias q="exit"
alias ga="git add $@"
alias gA="git add ."
alias gb="git branch"
alias gB="git branch $@"
alias gc=gtype
alias gC=gtype
alias gf="git fetch --prune"
alias gm="git mv $@"
alias gp="git push"
alias gpo="git push --set-upstream origin $(git branch --show-current)"
alias gP="git pull"
alias gs="git status"
alias gS="git switch $@"
alias gwa="git worktree add $@"
alias ".."="cd .."
alias pup="git fetch origin prod:prod && git merge prod"
alias plog="git log --graph --format='%Cgreen%h %Cred%aN%Cblue%d%Creset %s %C(yellow)(%cr)%Creset'"
# Ansi Color Escape Codes For Aesthetic Bash CLI Output
NORMAL='\033[0;39m'
BLACK='\033[0;30m'
DARK_GRAY='\033[1;30m'
RED='\033[0;31m'
LIGHT_RED='\033[1;31m'
GREEN='\033[0;32m'
LIGHT_GREEN='\033[1;32m'
ORANGE='\033[0;33m'
YELLOW='\033[1;33m'
BLUE='\033[0;34m'
LIGHT_BLUE='\033[1;34m'
PURPLE='\033[0;35m'
LIGHT_PURPLE='\033[1;35m'
CYAN='\033[0;36m'
LIGHT_CYAN='\033[1;36m'
LIGHT_GRAY='\033[0;37m'
WHITE='\033[1;37m'
# Better Git Logs.
## Using EMOJI-LOG (https://github.com/ahmadawais/Emoji-Log).
gcap() { #This is a helper function that is NEVER called
git commit -m "$*" && git push
}
# NEW.
gnew() {
gcap "📦 NEW: $@"
}
# IMPROVE.
gipr() {
gcap "👌 IMPROVE: $@"
}
# FIX.
gfix() {
gcap "🐛 FIX: $@"
}
# RELEASE.
grlz() {
gcap "🚀 RELEASE: $@"
}
# DOC.
gdoc() {
gcap "📖 DOC: $@"
}
# TEST.
gtst() {
gcap "🧪️ TEST: $@"
}
# BREAKING CHANGE.
gbrk() {
gcap "❗️ BREAKING: $@"
}
gtype() {
echo -e "$GREEN gnew$NORMAL -- 📦 NEW
$GREEN gipr$NORMAL -- 👌 IMPROVE
$GREEN gfix$NORMAL -- 🐛 FIX
$GREEN grlz$NORMAL -- 🚀 RELEASE
$GREEN gdoc$NORMAL -- 📖 DOC
$GREEN gtst$NORMAL -- 🧪️ TEST
$GREEN gbrk$NORMAL -- ❗️ BREAKING"
} .vscode/extensions.json{
"recommendations": [
//======================================================//
// Miscellanious Things //
//======================================================//
"alefragnani.bookmarks", //............................... Bookmark Management
"coenraads.bracket-pair-colorizer-2", //.................. Colorize bracket pairs
"inu1255.easy-snippet", //................................ Easier interface for modification of snippets and thier use
"ms-vsliveshare.vsliveshare", //.......................... Live share for collab editing (Like google docs but for VSCode)
"4tron.stack-overflow-view", //........................... Easily Search for and open Stack Overflow from within VSCode
"visualstudioexptteam.vscodeintellicode", //.............. VSCode Intellisense++
"tabnine.tabnine-vscode", //.............................. Intelligent Auto completions
"wattenberger.footsteps", //.............................. Jump between edited lines and highlight them visually too
//======================================================//
// Git Tools //
//======================================================//
"mhutchie.git-graph", //.................................. Visual Git Graph
"eamodio.gitlens", //..................................... Make git easy to use. See history, Diffs, and run Commands without needing to know the CLI
"neilbarkhina.gitdownloadazurerepos", //.................. Easily download Azure Repos (Requires using a PAT)
"codezombiech.gitignore", //.............................. Language Support got .gitignore files
"felipecaputo.git-project-manager", //.................... Easily Hop to other Git Projects on your local machine
//======================================================//
// Markdown Management //
//======================================================//
"shardulm94.trailing-spaces", //.......................... Remove Trailing spaces on document save
"yzhang.markdown-all-in-one",//........................... A Massive all in 1 markdown tool
"bierner.markdown-mermaid", //............................ Mermaid Chart Rendering
"bpruitt-goddard.mermaid-markdown-syntax-highlighting", // Code syntax highlighting
"takumii.markdowntable", //............................... Markdown Table Manipulation
"darkriszty.markdown-table-prettify", //.................. Align all table elements into an ordered structure for viewing AND editing
"mushan.vscode-paste-image", //........................... Make it so you can just paste images and they are added to a designated folder
"kisstkondoros.vscode-gutter-preview", //................. Image viewing on hover and in the gutter
"mdickin.markdown-shortcuts", //.......................... Shortcuts to help with editing like toggling bullet points
//======================================================//
// Aesthetics and Visual Aids //
//======================================================//
"oderwat.indent-rainbow", //.............................. Visually indent code with colored block columns
"mechatroner.rainbow-csv", //............................. If we View CSV files this makes for a great visual experience
"ibm.output-colorizer", //................................ Format the output in the VSCode Output pane
//======================================================//
// Task Management //
//======================================================//
"gruntfuggly.todo-tree", //............................... Task management that can be granularly defined with tags, icons, colors, etc.
//======================================================//
// File Viewing & Management //
//======================================================//
"mohsen1.prettify-json", //............................... JSON Prettify strings
"csholmq.excel-to-markdown-table", //..................... EXCEL content on the clipboard pasted as a markdown tablw
"janisdd.vscode-edit-csv", //............................. CSV Full on tabular editing of CSV's in VSCode that works with pipe delimited files
"tomoki1207.pdf", //...................................... PDF View PDF's in VSCode through PDF.js
"patbenatar.advanced-new-file", //........................ GENERAL Easier management of creating new files Remap the command for this EXT to Ctrl-N for best experience
"sleistner.vscode-fileutils", //.......................... GENERAL Move, Rename, Delete, etc. Files with keyboard only (QOL++)
"redhat.vscode-yaml", //.................................. YAML Language Support
"bierner.markdown-yaml-preamble", //...................... YAML Frontmatter preview as table
"tyriar.sort-lines", //................................... Sort Content lines
//======================================================//
// All Things Python //
//======================================================//
"jithurjacob.nbpreviewer", //............................. Jupyter Notebook Support and Viewing
"ms-toolsai.jupyter", //.................................. Jupyter Notebook Support and Viewing
"ms-python.vscode-pylance", //............................ Language Support
"ms-python.python", //.................................... Language Support
"formulahendry.code-runner", //........................... Code runner to run the language for output and not just python code
"littlefoxteam.vscode-python-test-adapter", //............ Python unit tests
"kevinrose.vsc-python-indent", //......................... Auto sane indentation
"njpwerner.autodocstring", //............................. Auto Documentation doc strings
"dongli.python-preview", //............................... Preview Execution elements of python code
"njqdev.vscode-python-typehint", //....................... Static type auto completion
"brainfit.vscode-importmagic", //......................... Fix missing package imports
"almenon.arepl" //........................................ A Python REPL
]
} .vscode/settings.json{// VSCode Settings
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"jupyter.askForKernelRestart": false,
"files.associations": {
"*.rstheme": "css"
},
"python.languageServer": "Pylance",
"workbench.editorAssociations": {
"*.ipynb": "jupyter.notebook.ipynb"
},
"vim.useSystemClipboard": true,
"explorer.confirmDragAndDrop": false,
"todo-tree.tree.showScanModeButton": false,
"todo-tree.general.tags": [
"BUG",
"HACK",
"FIXME",
"TODO",
"HOTFIX",
"DOC",
"TEST",
"QA"
],
"todo-tree.filtering.excludeGlobs": [
"**/.vscode"
],
"todo-tree.regex.regex": "(//|#|<!--|;|/\\*|^|^\\s*(-|\\d+.))\\s*($TAGS)",
"todo-tree.highlights.defaultHighlight": {
"icon": "arrow-right",
"type": "line",
"iconColour": "#ebdbb2",
"gutterIcon": true,
"fontStyle": "italic"
},
"todo-tree.highlights.customHighlight": {
"BUG": {
"icon": "bug",
"foreground": "#9d0006",
"iconColour": "#9d0006",
"fontWeight": "bold"
},
"HACK": {
"icon": "alert",
"foreground": "#cc241d",
"iconColour": "#cc241d",
"fontWeight": "bold"
},
"FIXME": {
"icon": "tools",
"foreground": "#b8bb26",
"iconColour": "#b8bb26"
},
"TODO": {
"icon": "check-circle",
"foreground": "#d16d0e",
"iconColour": "#d16d0e"
},
"HOTFIX": {
"icon": "flame",
"foreground": "#fb4934",
"iconColour": "#fb4934",
"fontWeight": "bold"
},
"DOC": {
"icon": "book",
"foreground": "#458588",
"iconColour": "#458588"
},
"TEST": {
"icon": "beaker",
"foreground": "#b16286",
"iconColour": "#b16286"
},
"QA": {
"icon": "eye",
"foreground": "#d79921",
"iconColour": "#d79921"
}
},
"editor.wrappingIndent": "indent",
"editor.overviewRulerBorder": false,
"editor.lineHeight": 24,
"[markdown]": {
"editor.quickSuggestions": true
},
"files.defaultLanguage": "markdown",
"git.enableSmartCommit": true,
"git.postCommitCommand": "sync",
"git.autofetch": true,
"git.confirmSync": false,
"gitlens.advanced.messages": {
"suppressGitMissingWarning": true
},
"gitlens.defaultDateFormat": "YYYY-MM-DD HHMM",
"gitlens.defaultTimeFormat": "HHMM",
"gitlens.defaultDateShortFormat": "YYYY-MM-DD",
"gitlens.gitCommands.skipConfirmations": [
"fetch:command",
"stash-push:command",
"switch:command",
"branch-create:menu"
],
"markdown.preview.breaks": true,
"prettier.singleQuote": false,
"explorer.confirmDelete": false,
"terminal.integrated.cursorBlinking": true,
"editor.cursorBlinking": "phase",
"editor.wordWrap": "on",
"workbench.editor.wrapTabs": true,
// Open the terminal in the currently opened file's directory
"terminal.integrated.cwd": "${fileDirname}",
// Set environment variable CUSTOM_VAR=test on all Linux terminals
"terminal.integrated.env.linux": {
"CUSTOM_VAR": "test"
},
// Configure Git Bash to be default and to use the .bashrc for the config file.
// Also Deactivate other profiles because we don't use them.
// Git Bash should now implicitly read your ~/.bashrc as well as local .vscode/.bashrc in that order
"terminal.integrated.profiles.windows": {
"Git Bash": {
"source": "Git Bash",
"icon": "terminal-bash",
"color": "terminal.ansiCyan",
},
"PowerShell": null,
"Command Prompt": null
},
"terminal.integrated.defaultProfile.windows": "Git Bash",
"cSpell.enableFiletypes": [
"bat",
"csv",
"csv (pipe)",
"dockerfile",
"dotenv",
"excel",
"gitignore",
"ini",
"json",
"jsonc",
"jupyter",
"log",
"markdown",
"powershell",
"r",
"shellscript",
"sql",
"vb",
"xml",
"yaml",
"yml"
],
"markdownlint.config": {
"default": true, // Default state for all rules
"extends": null, // Path to configuration file to extend
"MD001": true, // MD001/heading-increment/header-increment - Heading levels should only increment by one level at a time
"MD002": { "level": 1 },// MD002/first-heading-h1/first-header-h1 - First heading should be a top-level heading
"MD003": { "style": "atx" }, // MD003/heading-style/header-style - Heading style
"MD004": { "style": "dash" }, // MD004/ul-style - Unordered list style
"MD005": true, // MD005/list-indent - Inconsistent indentation for list items at the same level
"MD006": true, // MD006/ul-start-left - Consider starting bulleted lists at the beginning of the line
"MD007": { "indent": 2, "start_indented": false }, // MD007/ul-indent - Unordered list indentation
"MD009": { "br_spaces": 2, "list_item_empty_lines": false, "strict": false }, // MD009/no-trailing-spaces - Trailing spaces
"MD010": { "code_blocks": true }, // MD010/no-hard-tabs - Hard tabs
"MD011": true, // MD011/no-reversed-links - Reversed link syntax
"MD012": { "maximum": 1 }, // MD012/no-multiple-blanks - Multiple consecutive blank lines
"MD013": false, // MD013/line-length - Line length
"MD014": true, // MD014/commands-show-output - Dollar signs used before commands without showing output
"MD018": true, // MD018/no-missing-space-atx - No space after hash on atx style heading
"MD019": true, // MD019/no-multiple-space-atx - Multiple spaces after hash on atx style heading
"MD020": true, // MD020/no-missing-space-closed-atx - No space inside hashes on closed atx style heading
"MD021": true, // MD021/no-multiple-space-closed-atx - Multiple spaces inside hashes on closed atx style heading
"MD022": { "lines_above": 1, "lines_below": 1 }, // MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines
"MD023": true, // MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line
"MD024": { "allow_different_nesting": false, "siblings_only": false }, // MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content
"MD025": { "level": 1, "front_matter_title": "^\\s*title\\s*[:=]" }, // MD025/single-title/single-h1 - Multiple top-level headings in the same document
"MD026": { "punctuation": ".,;:!。,;:!" }, // MD026/no-trailing-punctuation - Trailing punctuation in heading
"MD027": true, // MD027/no-multiple-space-blockquote - Multiple spaces after blockquote symbol
"MD028": true, // MD028/no-blanks-blockquote - Blank line inside blockquote
"MD029": { "style": "one_or_ordered" }, // MD029/ol-prefix - Ordered list item prefix
"MD030": { "ul_single": 1, "ol_single": 1, "ul_multi": 1, "ol_multi": 1 }, // MD030/list-marker-space - Spaces after list markers
"MD031": { "list_items": true }, // MD031/blanks-around-fences - Fenced code blocks should be surrounded by blank lines
"MD032": true, // MD032/blanks-around-lists - Lists should be surrounded by blank lines
"MD033": { "allowed_elements": ["br","u","sub","sup","mark"] }, // MD033/no-inline-html - Inline HTML
"MD034": true, // MD034/no-bare-urls - Bare URL used
"MD035": { "style": "---" }, // MD035/hr-style - Horizontal rule style
"MD036": { "punctuation": ".,;:!?。,;:!?" }, // MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading
"MD037": true, // MD037/no-space-in-emphasis - Spaces inside emphasis markers
"MD038": true, // MD038/no-space-in-code - Spaces inside code span elements
"MD039": true, // MD039/no-space-in-links - Spaces inside link text
"MD040": true, // MD040/fenced-code-language - Fenced code blocks should have a language specified
"MD041": { "level": 1, "front_matter_title": "^\\s*title\\s*[:=]" }, // MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading
"MD042": true, // MD042/no-empty-links - No empty links
"MD043": false, // MD043/required-headings/required-headers - Required heading structure
"MD044": { "names": [], "code_blocks": false }, // MD044/proper-names - Proper names should have the correct capitalization
"MD045": true, // MD045/no-alt-text - Images should have alternate text (alt text)
"MD046": { "style": "fenced" }, // MD046/code-block-style - Code block style
"MD047": true, // MD047/single-trailing-newline - Files should end with a single newline character
"MD048": { "style": "backtick" } // MD048/code-fence-style - Code fence style
},
"trailing-spaces.trimOnSave": true,
"cSpell.enabledLanguageIds": [
"asciidoc",
"c",
"cpp",
"csharp",
"css",
"git-commit",
"go",
"graphql",
"handlebars",
"haskell",
"html",
"jade",
"java",
"javascript",
"javascriptreact",
"latex",
"less",
"markdown",
"php",
"plaintext",
"python",
"pug",
"restructuredtext",
"rust",
"scala",
"scss",
"text",
"typescript",
"typescriptreact",
"yaml",
"yml"
]
} But here's some of the stuff. I've honestly set up a lot of things and don't really want to go through and sanitize a lot of it to provide it here because its closely tied with my day job/s work. Enjoy :) |
Beta Was this translation helpful? Give feedback.
@fakoh We use a LOT of extensions, I also have a custom bash profile in the repo that gets loaded by our settings.json for git aliases and other things.
.vscode/.bashrc