Skip to content

Instantly share code, notes, and snippets.

@fand
Last active June 6, 2018 04:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fand/39a43ecbe779ae1695aa90ed1704b11f to your computer and use it in GitHub Desktop.
Save fand/39a43ecbe779ae1695aa90ed1704b11f to your computer and use it in GitHub Desktop.
atom.commands.add("atom-workspace", "custom:merge-panes", async () => {
const panes = atom.workspace.getCenter().getPanes()
const firstPane = panes.shift()
// loop through all panes except for the first pane
for (const pane of panes) {
for (const item of pane.getItems()) {
// if item is already in first pane, delete it, otherwise move it to first pane
if (firstPane.getItems().find(i => i.getPath() === item.getPath())) {
pane.destroyItem(item)
} else {
pane.moveItemToPane(item, firstPane)
}
}
}
})
# Your keymap
#
# Atom keymaps work similarly to style sheets. Just as style sheets use
# selectors to apply styles to elements, Atom keymaps use selectors to associate
# keystrokes with events in specific contexts. Unlike style sheets however,
# each selector can only be declared once.
#
# You can create a new keybinding in this file by typing "key" and then hitting
# tab.
#
# Here's an example taken from Atom's built-in keymap:
#
# 'atom-text-editor':
# 'enter': 'editor:newline'
#
# 'atom-workspace':
# 'ctrl-shift-p': 'core:move-up'
# 'ctrl-p': 'core:move-down'
#
# You can find more information about keymaps in these guides:
# * http://flight-manual.atom.io/using-atom/sections/basic-customization/#_customizing_keybindings
# * http://flight-manual.atom.io/behind-atom/sections/keymaps-in-depth/
#
# If you're having trouble with your keybindings not working, try the
# Keybinding Resolver: `Cmd+.` on macOS and `Ctrl+.` on other platforms. See the
# Debugging Guide for more information:
# * http://flight-manual.atom.io/hacking-atom/sections/debugging/#check-the-keybindings
#
# This file uses CoffeeScript Object Notation (CSON).
# If you are unfamiliar with CSON, you can read more about it in the
# Atom Flight Manual:
# http://flight-manual.atom.io/using-atom/sections/basic-customization/#_cson
'.platform-darwin atom-text-editor':
'cmd-shift-l': 'grammar-selector:show'
'.editor':
'shift-space': 'autocomplete:toggle'
'ctrl-i': 'editor:auto-indent'
# 'tab': 'editor:auto-indent'
'ctrl-x 0': 'pane:close'
'ctrl-x 2': 'pane:split-down'
'ctrl-x 3': 'pane:split-right'
'ctrl-t': 'window:focus-next-pane'
'ctrl-a': 'editor:move-to-first-character-of-line'
'ctrl-e': 'editor:move-to-end-of-line'
'ctrl-j': 'editor:backspace-to-beginning-of-word'
'ctrl-l': 'emacs:recenter'
'ctrl-h': 'core:backspace'
'ctrl-d': 'core:delete'
# 'ctrl-k': 'editor:delete-line'
'ctrl-/': 'core:undo'
'alt-/': 'editor:toggle-line-comments'
'alt-shift-p': 'command-palette:toggle'
'shift-ctrl-n': 'core:select-down'
'shift-ctrl-p': 'core:select-up'
'shift-ctrl-f': 'core:select-right'
'shift-ctrl-b': 'core:select-left'
'shift-ctrl-v': 'core:select-page-down'
'atom-text-editor:not([mini])':
# 'tab': 'editor:auto-indent'
'shift-tab': 'snippets:expand'
'.platform-darwin':
'alt-cmd-p': 'project-manager:toggle'
'atom-text-editor':
'alt-cmd-p' : 'project-manager : toggle'
'alt-cmd-l' : 'editor : log-cursor-scope'
'atom-workspace':
'ctrl-x ctrl-x e': 'atom-keyboard-macros:repeat_last_kbd_macro'
'.platform-darwin, .platform-win32, .platform-linux':
'ctrl-x l': 'go-to-line:toggle'
'atom-text-editor:not([mini]).typescript-editor':
'alt-cmd-enter': 'typescript:go-to-declaration'
'shift-alt-cmd-enter': 'typescript:return-from-declaration'
'.platform-darwin .ide-haskell atom-text-editor[data-grammar~="haskell"]':
'alt-cmd-enter': 'ide-haskell-hasktags:go-to-declaration'
# for windows
'.workspace':
'ctrl-p': 'core:move-up'
'ctrl-n': 'core:move-down'
'ctrl-b': 'core:move-left'
'ctrl-f': 'core:move-right'
'ctrl-v': 'core:page-down'
'ctrl-c': 'core:copy'
'ctrl-w': 'core:cut'
'ctrl-y': 'core:paste'
'ctrl-k': 'editor:cut-to-end-of-line'
'ctrl-j': 'editor:newline'
'alt-f': 'find-and-replace:show'
'alt-w': 'core:close'
'alt-d': 'find-and-replace:select-next'
'alt-,': 'settings-view:open'
'alt-[': 'editor:outdent-selected-rows'
'alt-]': 'editor:indent-selected-rows'
'ctrl-0': 'tree-view:toggle-focus'
'alt-t': 'application:new-file'
'alt-s': 'core:save'
'alt-a': 'core:select-all'
'.tree-view':
'ctrl-p': 'core:move-up'
'ctrl-n': 'core:move-down'
'ctrl-b': 'tree-view:collapse'
'ctrl-f': 'tree-view:expand-item'
# Disable ctrl-k bindings
'body':
'ctrl-k ctrl-alt-w': 'unset!'
'ctrl-k ctrl-down': 'unset!'
'ctrl-k ctrl-left': 'unset!'
'ctrl-k ctrl-right': 'unset!'
'ctrl-k ctrl-n': 'unset!'
'ctrl-k ctrl-p': 'unset!'
'ctrl-k ctrl-w': 'unset!'
'ctrl-k down': 'unset!'
'ctrl-k left': 'unset!'
'ctrl-k right': 'unset!'
'ctrl-k up': 'unset!'
'ctrl-k ctrl-up': 'unset!'
'ctrl-k ctrl-u': 'unset!'
'ctrl-k ctrl-l': 'unset!'
'ctrl-k ctrl-d': 'unset!'
'ctrl-k ctrl-b': 'unset!'
'ctrl-k ctrl-g': 'unset!'
'ctrl-k ctrl-0': 'unset!'
'ctrl-k ctrl-1': 'unset!'
'ctrl-k ctrl-2': 'unset!'
'ctrl-k ctrl-3': 'unset!'
'ctrl-k ctrl-4': 'unset!'
'ctrl-k ctrl-5': 'unset!'
'ctrl-k ctrl-6': 'unset!'
'ctrl-k ctrl-7': 'unset!'
'ctrl-k ctrl-8': 'unset!'
'ctrl-k ctrl-9': 'unset!'
[
{
"name": "about",
"version": "1.8.1"
},
{
"name": "activate-power-mode",
"version": "2.7.0"
},
{
"name": "aesthetic-ui",
"version": "4.0.0",
"theme": "ui"
},
{
"name": "apex-muted-ui",
"version": "0.1.4",
"theme": "ui"
},
{
"name": "apex-ui",
"version": "1.2.0",
"theme": "ui"
},
{
"name": "archive-view",
"version": "0.64.3"
},
{
"name": "atom-beautify",
"version": "0.32.5"
},
{
"name": "atom-dark-fusion-syntax",
"version": "2.2.1",
"theme": "syntax"
},
{
"name": "atom-dark-syntax",
"version": "0.29.0",
"theme": "syntax"
},
{
"name": "atom-dark-ui",
"version": "0.53.2",
"theme": "ui"
},
{
"name": "atom-ide-ui",
"version": "0.12.0"
},
{
"name": "atom-light-syntax",
"version": "0.29.0",
"theme": "syntax"
},
{
"name": "atom-light-ui",
"version": "0.46.2",
"theme": "ui"
},
{
"name": "atom-material-syntax",
"version": "1.0.8",
"theme": "syntax"
},
{
"name": "atom-material-ui",
"version": "2.1.3",
"theme": "ui"
},
{
"name": "atom-monokai",
"version": "0.10.9",
"theme": "syntax"
},
{
"name": "atom-typescript",
"version": "12.5.1"
},
{
"name": "auto-detect-indentation",
"version": "1.3.0"
},
{
"name": "autoclose-html",
"version": "0.23.0"
},
{
"name": "autocomplete-atom-api",
"version": "0.10.7"
},
{
"name": "autocomplete-css",
"version": "0.17.5"
},
{
"name": "autocomplete-glsl",
"version": "0.2.3"
},
{
"name": "autocomplete-haskell",
"version": "1.0.1"
},
{
"name": "autocomplete-html",
"version": "0.8.4"
},
{
"name": "autocomplete-plus",
"version": "2.40.6"
},
{
"name": "autocomplete-snippets",
"version": "1.12.0"
},
{
"name": "autoflow",
"version": "0.29.3"
},
{
"name": "autosave",
"version": "0.24.6"
},
{
"name": "background-tips",
"version": "0.28.0"
},
{
"name": "base16-tomorrow-dark-theme",
"version": "1.5.0",
"theme": "syntax"
},
{
"name": "base16-tomorrow-light-theme",
"version": "1.5.0",
"theme": "syntax"
},
{
"name": "bookmarks",
"version": "0.45.1"
},
{
"name": "bracket-matcher",
"version": "0.89.2"
},
{
"name": "busy-signal",
"version": "1.4.3"
},
{
"name": "city-lights-syntax",
"version": "1.1.8",
"theme": "syntax"
},
{
"name": "city-lights-ui",
"version": "1.3.3",
"theme": "ui"
},
{
"name": "command-palette",
"version": "0.43.5"
},
{
"name": "dalek",
"version": "0.2.2"
},
{
"name": "dash-syntax",
"version": "0.4.1",
"theme": "syntax"
},
{
"name": "dash-ui",
"version": "0.4.4",
"theme": "ui"
},
{
"name": "deprecation-cop",
"version": "0.56.9"
},
{
"name": "dev-live-reload",
"version": "0.48.1"
},
{
"name": "encoding-selector",
"version": "0.23.8"
},
{
"name": "exception-reporting",
"version": "0.43.1"
},
{
"name": "file-icons",
"version": "2.1.21"
},
{
"name": "find-and-replace",
"version": "0.215.9"
},
{
"name": "fuzzy-finder",
"version": "1.8.1"
},
{
"name": "git-blame",
"version": "1.6.0"
},
{
"name": "git-diff",
"version": "1.3.9"
},
{
"name": "git-plus",
"version": "7.10.2"
},
{
"name": "github",
"version": "0.14.5"
},
{
"name": "go-debug",
"version": "1.6.2"
},
{
"name": "go-plus",
"version": "5.8.3"
},
{
"name": "go-signature-statusbar",
"version": "1.2.3"
},
{
"name": "go-to-line",
"version": "0.33.0"
},
{
"name": "goto-definition",
"version": "1.3.4"
},
{
"name": "grammar-selector",
"version": "0.50.1"
},
{
"name": "haskell-ghc-mod",
"version": "2.2.3"
},
{
"name": "haskell-pointfree",
"version": "0.2.0"
},
{
"name": "haskell-scry",
"version": "1.0.8"
},
{
"name": "hey-pane",
"version": "1.1.0"
},
{
"name": "hyperlink-hyperclick",
"version": "2.0.0"
},
{
"name": "ide-csharp",
"version": "0.6.2"
},
{
"name": "ide-flowtype",
"version": "0.23.0"
},
{
"name": "ide-haskell",
"version": "2.3.1"
},
{
"name": "ide-haskell-cabal",
"version": "2.2.0"
},
{
"name": "ide-haskell-hasktags",
"version": "0.0.15"
},
{
"name": "ide-haskell-hoogle",
"version": "0.1.2"
},
{
"name": "ide-haskell-repl",
"version": "0.8.0"
},
{
"name": "ide-python",
"version": "0.10.0"
},
{
"name": "ide-typescript",
"version": "0.7.6"
},
{
"name": "image-view",
"version": "0.62.4"
},
{
"name": "incompatible-packages",
"version": "0.27.3"
},
{
"name": "indent-guide-improved",
"version": "1.4.13"
},
{
"name": "intentions",
"version": "1.1.5"
},
{
"name": "jackhammer-syntax",
"version": "1.1.0",
"theme": "syntax"
},
{
"name": "js-hyperclick",
"version": "1.13.0"
},
{
"name": "keybinding-resolver",
"version": "0.38.1"
},
{
"name": "language-autohotkey2",
"version": "1.0.1"
},
{
"name": "language-babel",
"version": "2.85.0"
},
{
"name": "language-c",
"version": "0.59.3"
},
{
"name": "language-clojure",
"version": "0.22.7"
},
{
"name": "language-coffee-script",
"version": "0.49.3"
},
{
"name": "language-csharp",
"version": "1.0.1"
},
{
"name": "language-css",
"version": "0.42.10"
},
{
"name": "language-gfm",
"version": "0.90.3"
},
{
"name": "language-git",
"version": "0.19.1"
},
{
"name": "language-glsl",
"version": "2.0.4"
},
{
"name": "language-go",
"version": "0.45.3"
},
{
"name": "language-haskell",
"version": "1.17.7"
},
{
"name": "language-haskell-scoped",
"version": "0.1.0"
},
{
"name": "language-hatena",
"version": "0.2.5"
},
{
"name": "language-html",
"version": "0.49.0"
},
{
"name": "language-hyperlink",
"version": "0.16.3"
},
{
"name": "language-java",
"version": "0.29.0"
},
{
"name": "language-javascript",
"version": "0.128.5"
},
{
"name": "language-json",
"version": "0.19.1"
},
{
"name": "language-less",
"version": "0.34.2"
},
{
"name": "language-make",
"version": "0.22.3"
},
{
"name": "language-mustache",
"version": "0.14.5"
},
{
"name": "language-objective-c",
"version": "0.15.1"
},
{
"name": "language-perl",
"version": "0.38.1"
},
{
"name": "language-php",
"version": "0.43.2"
},
{
"name": "language-property-list",
"version": "0.9.1"
},
{
"name": "language-python",
"version": "0.49.5"
},
{
"name": "language-ruby",
"version": "0.71.4"
},
{
"name": "language-ruby-on-rails",
"version": "0.25.3"
},
{
"name": "language-rust",
"version": "0.4.12"
},
{
"name": "language-sass",
"version": "0.61.4"
},
{
"name": "language-scala",
"version": "1.1.9"
},
{
"name": "language-scheme",
"version": "1.4.0"
},
{
"name": "language-shellscript",
"version": "0.26.3"
},
{
"name": "language-source",
"version": "0.9.0"
},
{
"name": "language-sql",
"version": "0.25.10"
},
{
"name": "language-text",
"version": "0.7.4"
},
{
"name": "language-todo",
"version": "0.29.4"
},
{
"name": "language-toml",
"version": "0.18.2"
},
{
"name": "language-typescript",
"version": "0.3.3"
},
{
"name": "language-vue",
"version": "0.23.1"
},
{
"name": "language-xml",
"version": "0.35.2"
},
{
"name": "language-yaml",
"version": "0.32.0"
},
{
"name": "line-ending-selector",
"version": "0.7.6"
},
{
"name": "link",
"version": "0.31.4"
},
{
"name": "linter",
"version": "2.2.0"
},
{
"name": "linter-eslint",
"version": "8.4.1"
},
{
"name": "linter-glsl",
"version": "2.1.4"
},
{
"name": "linter-hlint",
"version": "2.0.0"
},
{
"name": "linter-rust",
"version": "0.8.5"
},
{
"name": "linter-tslint",
"version": "1.9.1"
},
{
"name": "linter-ui-default",
"version": "1.7.1"
},
{
"name": "magical-selection",
"version": "2.0.3"
},
{
"name": "markdown-preview",
"version": "0.159.20"
},
{
"name": "markdown-table-editor",
"version": "1.1.1"
},
{
"name": "markdown-toc",
"version": "0.4.2"
},
{
"name": "metrics",
"version": "1.2.6"
},
{
"name": "minimap",
"version": "4.29.8"
},
{
"name": "move-cursor-improved",
"version": "0.3.4"
},
{
"name": "no-title-bar",
"version": "1.11.4"
},
{
"name": "node-debugger",
"version": "1.10.1"
},
{
"name": "notifications",
"version": "0.70.5"
},
{
"name": "nucleus-dark-ui",
"version": "0.12.3",
"theme": "ui"
},
{
"name": "one-dark-syntax",
"version": "1.8.2",
"theme": "syntax"
},
{
"name": "one-dark-ui",
"version": "1.12.1",
"theme": "ui"
},
{
"name": "one-light-syntax",
"version": "1.8.2",
"theme": "syntax"
},
{
"name": "one-light-ui",
"version": "1.12.1",
"theme": "ui"
},
{
"name": "open-on-github",
"version": "1.3.1"
},
{
"name": "package-generator",
"version": "1.3.0"
},
{
"name": "pigments",
"version": "0.40.2"
},
{
"name": "plantuml-viewer",
"version": "0.7.2"
},
{
"name": "seti-syntax",
"version": "1.1.3",
"theme": "syntax"
},
{
"name": "seti-ui",
"version": "1.10.0",
"theme": "ui"
},
{
"name": "settings-view",
"version": "0.254.2"
},
{
"name": "snippets",
"version": "1.3.3"
},
{
"name": "solarized-dark-syntax",
"version": "1.1.4",
"theme": "syntax"
},
{
"name": "solarized-light-syntax",
"version": "1.1.4",
"theme": "syntax"
},
{
"name": "spell-check",
"version": "0.73.4"
},
{
"name": "status-bar",
"version": "1.8.15"
},
{
"name": "styleguide",
"version": "0.49.11"
},
{
"name": "supercollider",
"version": "0.9.1"
},
{
"name": "swackets",
"version": "0.35.0"
},
{
"name": "symbols-view",
"version": "0.118.2"
},
{
"name": "sync-settings",
"version": "0.8.6"
},
{
"name": "tabs",
"version": "0.109.1"
},
{
"name": "teletype",
"version": "0.13.3"
},
{
"name": "timecop",
"version": "0.36.2"
},
{
"name": "touchbar",
"version": "0.10.1"
},
{
"name": "tree-view",
"version": "0.222.0"
},
{
"name": "update-package-dependencies",
"version": "0.13.1"
},
{
"name": "videoplayer",
"version": "1.4.0"
},
{
"name": "vue2-autocomplete",
"version": "0.1.0-alpha.4"
},
{
"name": "wakatime",
"version": "7.0.4"
},
{
"name": "welcome",
"version": "0.36.6"
},
{
"name": "whitespace",
"version": "0.37.5"
},
{
"name": "wrap-guide",
"version": "0.40.3"
},
{
"name": "yeti-syntax",
"version": "0.1.2",
"theme": "syntax"
},
{
"name": "yeti-ui",
"version": "0.1.6",
"theme": "ui"
},
{
"name": "zentabs",
"version": "0.8.9"
}
]
{
"activate-power-mode": {
"autoToggle": false,
"comboMode": {
"activationThreshold": [
"0",
"20",
"50",
"100",
"200",
"500"
]
},
"particles": {
"colours": {
"type": "random"
},
"size": {
"max": 10
},
"spawnCount": {
"max": 20
}
},
"plugins": {
"playAudio": true,
"screenShake": true
},
"screenShake": {
"minIntensity": 2
}
},
"atom-beautify": {
"general": {
"_analyticsUserId": "d61dbcd1-122c-47e8-9fb3-f1a6a07bcc92",
"muteAllErrors": true,
"showLoadingView": false
},
"haskell": {
"beautify_on_save": true
}
},
"atom-ctags": {
"autoBuildTagsWhenActive": true,
"buildTimeout": 30000,
"cmd": "/usr/local/bin/ctags",
"disableComplete": true
},
"atom-haskell": {
"hasAddedConfiguration": true
},
"atom-ide-ui": {
"atom-ide-diagnostics-ui": {
"autoVisibility": true
}
},
"atom-material-ui": {
"colors": {
"abaseColor": "#80deea",
"accentColor": "#528c94",
"predefinedColor": "Cyan"
},
"tabs": {
"compactTabs": true
},
"ui": {
"useAnimations": false
}
},
"autocomplete-haskell": {
"defaultHintPanelVisibility": "Hidden"
},
"block-cursor": {
"global": {
"blinkOff": {
"backgroundColor": "#ffffff",
"borderColor": "#ff2600",
"borderStyle": "underline"
},
"blinkOn": {
"backgroundColor": "#000000",
"borderColor": "#ff2600"
}
}
},
"core": {
"autoHideMenuBar": true,
"closeEmptyWindows": false,
"disabledPackages": [
"symbols-view",
"goto-definition",
"linter-tslint",
"linter",
"ide-typescript",
"linter-hlint"
],
"packagesWithKeymapsDisabled": [
"git-blame"
],
"projectHome": "/Users/amagi/src/github.com/fand",
"telemetryConsent": "limited",
"themes": [
"nucleus-dark-ui",
"one-dark-syntax"
],
"titleBar": "custom-inset",
"uriHandlerRegistration": "always",
"useTreeSitterParsers": true
},
"editor": {
"fontFamily": "\"Ricty Diminished\"",
"fontSize": 16,
"scrollPastEnd": true,
"showInvisibles": true
},
"exception-reporting": {
"userId": "5da1e855-3c8c-4dd9-b355-6aa16c8271e7"
},
"git-blame": {
"colorCommitAuthors": true,
"ignoreWhiteSpaceDiffs": true,
"showOnlyLastNames": true
},
"goto-definition": {
"performanceMode": true
},
"haskell-ghc-mod": {
"ghcModMessages": "upi",
"initTimeout": 10,
"interactiveActionTimeout": 10,
"interactiveInactivityTimeout": 10,
"lowMemorySystem": true,
"onChangeCheck": true,
"onChangeLint": true,
"onSelectionShow": "typeAndInfo"
},
"ide-flowtype": {
"tryFlowBin": true
},
"ide-haskell": {
"autoHideOutput": true,
"messageDisplayFrontend": "linter",
"onSavePrettify": true,
"startupMessageIdeBackend": false,
"switchTabOnCheck": false
},
"ide-haskell-cabal": {
"cabal": {
"activeGhcVersion": "8.0"
}
},
"ide-haskell-repl": {
"defaultRepl": "stack"
},
"ide-python": {
"pylsPlugins": {
"pycodestyle": {
"enabled": false
}
}
},
"ide-typescript": {
"javascriptSupport": false
},
"linter": {
"disabledProviders": [
"ESLint"
]
},
"linter-tslint": {
"fixOnSave": true
},
"linter-ui-default": {
"alwaysTakeMinimumSpace": true,
"showDecorations": false,
"showProviderName": true,
"showStatusBar": false,
"useBusySignal": false
},
"magical-selection": {
"goDark": true
},
"markdown-preview": {
"breakOnSingleNewline": true
},
"neon-cursor": {
"cursorType": "box"
},
"no-title-bar": {
"metaKeyMouseDrag": true
},
"prettier-atom": {
"formatOnSaveOptions": {
"enabled": true,
"excludedGlobs": [
"*.json"
],
"isDisabledIfNotInPackageJson": true
},
"prettierOptions": {
"bracketSpacing": false,
"semi": false
}
},
"seti-ui": {
"compactView": true,
"displayIgnored": false,
"hideProjectTab": true,
"hideTitleBar": true
},
"spell-check": {
"useLocales": false
},
"supercollider": {
"updateProjectFolders": false
},
"sync-settings": {},
"tidalcycles": {
"ghciPath": "stack ghci"
},
"touchbar": {
"buttons": "[{\"type\":\"button\",\"name\":\"Config 1523865512880\",\"label\":\"VEDA\",\"command\":\"veda:toggle\",\"color\":\"#00f7db\"}]"
},
"veda": {
"pixelRatio": 1
},
"videoplayer": {
"playback": {
"loop": true
}
},
"wakatime": {
"apikey": "Enter your api key..."
},
"welcome": {
"showOnStartup": false
},
"whitespace": {
"ignoreWhitespaceOnCurrentLine": false
},
"zentabs": {
"maximumOpenedTabs": 4,
"neverCloseUnsaved": true
}
}
# Your snippets
#
# Atom snippets allow you to enter a simple prefix in the editor and hit tab to
# expand the prefix into a larger code block with templated values.
#
# You can create a new snippet in this file by typing "snip" and then hitting
# tab.
#
# An example CoffeeScript snippet to expand log to console.log:
#
# '.source.coffee':
# 'Console log':
# 'prefix': 'log'
# 'body': 'console.log $1'
#
# Each scope (e.g. '.source.coffee' above) can only be declared once.
#
# This file uses CoffeeScript Object Notation (CSON).
# If you are unfamiliar with CSON, you can read more about it in the
# Atom Flight Manual:
# http://flight-manual.atom.io/using-atom/sections/basic-customization/#_cson
'.source.js, .source.jsx, .source.ts, .source.tsx':
'Console log':
'prefix': 'l'
'body': 'console.log($1);'
'Class':
'prefix': 'c'
'body': """
class $1 {
$2
}
"""
'Function':
'prefix': 'f'
'body': """
function ($1) {
$2;
}
"""
'Arrow':
'prefix': 'a'
'body': """
($1) => {
$2;
}
"""
'Arrow oneliner':
'prefix': 'al'
'body': '$1 => $2'
'Method':
'prefix': 'm'
'body': """
$1 ($2) {
$3;
}
"""
'module':
'prefix': 'me'
'body': """
'use strict';
module.exports = $1;
"""
'ES6 module class':
'prefix': 'ex'
'body': 'export default $1;'
'Foreach Arrow':
'prefix': '.fe'
'body': '.forEach()'
'If error':
'prefix': 'ife'
'body': """
if (err) { throw err; }$1
"""
'JSDoc':
'prefix': 'd'
'body': """
/**
* $1
*/
"""
'JSDoc param':
'prefix': 'pa'
'body': '@param {$1} $2'
'require':
'prefix': 'r'
'body': "require('');"
'Import':
'prefix': 'im'
'body': "import $1 from '';"
'noop':
'prefix': 'no'
'body': "() => {}"
'.source.perl':
'Dump':
'prefix': 'd'
'body': 'use Data::Dumper; local $Data::Dumper::Sortkeys = 1; warn Dumper ($1);'
'New script':
'prefix': 'n'
'body': """
use strict;
use warnings;
use utf8;
$1;
"""
'New module':
'prefix': 'm'
'body': """
package $1;
use strict;
use warnings;
use utf8;
$2;
"""
'Subroutine':
'prefix': 's'
'body': """
sub $1 {
$2
}
"""
'Subtest':
'prefix': 'st'
'body': """
subtest '$1' => subtest{
$2
};
"""
# For Hatena-Epic
'Hatena::Epic':
'prefix': 'h'
'body': 'Hatena::Epic::'
'Hatena::Epic::Service':
'prefix': 'hs'
'body': 'Hatena::Epic::Service::'
'Hatena::Epic::Model':
'prefix': 'hm'
'body': 'Hatena::Epic::Model::'
'Hatena::Epic::Batch':
'prefix': 'hb'
'body': 'Hatena::Epic::Batch::'
'.source.gfm':
'Snippet':
'prefix': 'sn'
'body': """
```$1
```
"""
'Snippet JavaScript':
'prefix': 'sj'
'body': """
```javascript
$1
```
"""
'Snippet Perl':
'prefix': 'sp'
'body': """
```perl
$1
```
"""
/*
* Your Stylesheet
*
* This stylesheet is loaded when Atom starts up and is reloaded automatically
* when it is changed and saved.
*
* Add your own CSS or Less to fully customize Atom.
* If you are unfamiliar with Less, you can read more about it here:
* http://lesscss.org
*/
/*
* Examples
* (To see them, uncomment and save)
*/
// style the background color of the tree view
.tree-view {
// background-color: whitesmoke;
}
// style the background and foreground colors on the atom-text-editor-element itself
atom-text-editor {
// color: white;
// background-color: hsl(180, 24%, 12%);
font-family: "Ricty Diminished";
}
// style UI elements inside atom-text-editor
atom-text-editor .cursor {
position: absolute;
border: 1px solid transparent;
background-color: rgba(0, 200, 222, 0.4);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment