Skip to content

Commit

Permalink
update dotfiles
Browse files Browse the repository at this point in the history
  • Loading branch information
dmmulroy committed Dec 31, 2023
1 parent b754a5a commit ebbee80
Show file tree
Hide file tree
Showing 58 changed files with 621 additions and 201 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
223 changes: 223 additions & 0 deletions .config/after/syntax/reason.vim
Original file line number Diff line number Diff line change
@@ -0,0 +1,223 @@
" Vim syntax file
" Language: Reason (Forked from Rust)
" Maintainer: (Jordan - for Reason changes) Patrick Walton <[email protected]>
" Maintainer: Ben Blum <[email protected]>
" Maintainer: Chris Morgan <[email protected]>
" Last Change: January 29, 2015
" Portions Copyright (c) 2015-present, Facebook, Inc. All rights reserved.

if version < 600
syntax clear
elseif exists("b:current_syntax") && b:current_syntax == "reason"
finish
endif

" Syntax definitions {{{1
" Basic keywords {{{2
syn keyword reasonConditional try switch if else for while
syn keyword reasonOperator as to downto

" syn keyword reasonKeyword fun nextgroup=reasonFuncName skipwhite skipempty
syn match reasonAssert "\<assert\(\w\)*"
syn match reasonFailwith "\<failwith\(\w\)*"

syn keyword reasonStorage when where fun mutable class pub pri val inherit let external rec nonrec and module type exception open include constraint
" FIXME: Scoped impl's name is also fallen in this category

syn match reasonIdentifier contains=reasonIdentifierPrime "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained
syn match reasonFuncName "\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\)\%([^[:cntrl:][:punct:][:space:]]\|_\)*" display contained
"
" syn match labelArgument "\(\l\|_\)\(\w\|'\)*::\(?\)\?"lc=0 "Allows any space between label name and ::
" syn match labelArgumentPunned "::\(?\)\?\(\l\|_\)\(\w\|'\)*"lc=0 "Allows any space between label name and ::
syn match labelArgument "\~\(\l\|_\)\(\w\|'\)*"lc=0 "Allows any space between label name and ::
syn match labelArgumentPunned "\~\(\l\|_\)\(\w\|'\)*\(?\)\?"lc=0 "Allows any space between label name and ::

syn match reasonConstructor "\<\u\(\w\|'\)*\>"
" Polymorphic variants
syn match reasonConstructor "`\w\(\w\|'\)*\>"

syn match reasonModPath "\<\u\(\w\|'\)* *\."he=e-1
syn match reasonModPath "\(\<open\s\+\)\@<=\u\(\w\|\.\)*"
syn match reasonModPath "\(\<include\s\+\)\@<=\u\(\w\|\.\)*"
syn match reasonModPath "\(\<module\s\+\)\@<=\u\(\w\|\.\)*"
syn match reasonModPath "\(\<module\s\+\u\w*\s*=\s*\)\@<=\u\(\w\|\.\)*"


" {} are handled by reasonFoldBraces


" Built-in types {{{2
syn keyword reasonType result int float option list array unit ref bool string

" Things from the libstd v1 prelude (src/libstd/prelude/v1.rs) {{{2
" This section is just straight transformation of the contents of the prelude,
" to make it easy to update.

" Reexported functions {{{3
" There’s no point in highlighting these; when one writes drop( or drop::< it
" gets the same highlighting anyway, and if someone writes `let drop = …;` we
" don’t really want *that* drop to be highlighted.
"syn keyword reasonFunction drop

" Reexported types and traits {{{3
syn keyword reasonEnum Option
syn keyword reasonConstructor Some None
syn keyword reasonEnum Result
syn keyword reasonConstructor Ok Error

" Other syntax {{{2
syn keyword reasonSelf self
syn keyword reasonBoolean true false

" This is merely a convention; note also the use of [A-Z], restricting it to
" latin identifiers rather than the full Unicode uppercase. I have not used
" [:upper:] as it depends upon 'noignorecase'
"syn match reasonCapsIdent display "[A-Z]\w\(\w\)*"

syn match reasonOperator display "\%(+\|-\|/\|*\|=\|\^\|&\||\|!\|>\|<\|%\)=\?"
" This one isn't *quite* right, as we could have binary-& with a reference

" This isn't actually correct; a closure with no arguments can be `|| { }`.
" Last, because the & in && isn't a sigil
syn match reasonOperator display "&&\|||"
" This is reasonArrowCharacter rather than reasonArrow for the sake of matchparen,
" so it skips the ->; see http://stackoverflow.com/a/30309949 for details.
syn match reasonArrowCharacter display "=>"

syn match reasonEscapeError display contained /\\./
syn match reasonEscape display contained /\\\([nrt0\\'"]\|x\x\{2}\)/
syn match reasonEscapeUnicode display contained /\\\(u\x\{4}\|U\x\{8}\)/
syn match reasonEscapeUnicode display contained /\\u{\x\{1,6}}/
syn match reasonStringContinuation display contained /\\\n\s*/
syn region reasonString start=+b"+ skip=+\\\\\|\\"+ end=+"+ contains=reasonEscape,reasonEscapeError,reasonStringContinuation
syn region reasonString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=reasonEscape,reasonEscapeUnicode,reasonEscapeError,reasonStringContinuation,@Spell
syn region reasonString start='b\?r\z(#*\)"' end='"\z1' contains=@Spell

syn region reasonMultilineString start=+b{|+ skip=+\\\\\|\\"+ end=+|}+ contains=reasonEscape,reasonEscapeError,reasonStringContinuation
syn region reasonMultilineString start=+{|+ end=+|}+ contains=reasonEscape,reasonEscapeUnicode,reasonEscapeError,reasonStringContinuation,@Spell


" https://github.com/pangloss/vim-javascript/blob/master/syntax/javascript.vim
" lc=1 means leading context, for "not backslashed"
syntax region reasonTemplateExpression contained matchgroup=reasonTemplateBraces start=+\(^\|[^\\]\)${+lc=1 end=+}+ contains=@interpolation keepend
syntax region reasonTemplateString start=+`\($\| \)+ skip=+\\`+ end=+`+ contains=reasonTemplateExpression,jsSpecial,@Spell extend
syntax match reasonTaggedTemplate /\<\K\k*\ze`/ nextgroup=reasonTemplateString


syn region reasonAttribute start="#!\?\[" end="\]" contains=reasonString,reasonDerive
" This list comes from src/libsyntax/ext/deriving/mod.rs
" Some are deprecated (Encodable, Decodable) or to be removed after a new snapshot (Show).

" Number literals
syn match reasonDecNumber display "\<[0-9][0-9_]*\%([iu]\%(size\|8\|16\|32\|64\)\)\="
syn match reasonHexNumber display "\<0x[a-fA-F0-9_]\+\%([iu]\%(size\|8\|16\|32\|64\)\)\="
syn match reasonOctNumber display "\<0o[0-7_]\+\%([iu]\%(size\|8\|16\|32\|64\)\)\="
syn match reasonBinNumber display "\<0b[01_]\+\%([iu]\%(size\|8\|16\|32\|64\)\)\="

" Special case for numbers of the form "1." which are float literals, unless followed by
" an identifier, which makes them integer literals with a method call or field access,
" or by another ".", which makes them integer literals followed by the ".." token.
" (This must go first so the others take precedence.)
syn match reasonFloat display "\<[0-9][0-9_]*\.\%([^[:cntrl:][:space:][:punct:][:digit:]]\|_\|\.\)\@!"
" To mark a number as a normal float, it must have at least one of the three things integral values don't have:
" a decimal point and more numbers; an exponent; and a type suffix.
syn match reasonFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\%([eE][+-]\=[0-9_]\+\)\=\(f32\|f64\)\="
syn match reasonFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\=\%([eE][+-]\=[0-9_]\+\)\(f32\|f64\)\="
syn match reasonFloat display "\<[0-9][0-9_]*\%(\.[0-9][0-9_]*\)\=\%([eE][+-]\=[0-9_]\+\)\=\(f32\|f64\)"

" For the benefit of delimitMate

syn match reasonCharacterInvalid display contained /b\?'\zs[\n\r\t']\ze'/
" The groups negated here add up to 0-255 but nothing else (they do not seem to go beyond ASCII).
syn match reasonCharacterInvalidUnicode display contained /b'\zs[^[:cntrl:][:graph:][:alnum:][:space:]]\ze'/
syn match reasonCharacter /b'\([^\\]\|\\\(.\|x\x\{2}\)\)'/ contains=reasonEscape,reasonEscapeError,reasonCharacterInvalid,reasonCharacterInvalidUnicode
syn match reasonCharacter /'\([^\\]\|\\\(.\|x\x\{2}\|u\x\{4}\|U\x\{8}\|u{\x\{1,6}}\)\)'/ contains=reasonEscape,reasonEscapeUnicode,reasonEscapeError,reasonCharacterInvalid

syn match reasonShebang /\%^#![^[].*/
syn region reasonCommentLine start="//" end="$" contains=reasonTodo,@Spell
" syn region reasonCommentLineDoc start="//\%(//\@!\|!\)" end="$" contains=reasonTodo,@Spell
syn region reasonCommentBlock matchgroup=reasonCommentBlock start="/\*\%(!\|\*[*/]\@!\)\@!" end="\*/" contains=reasonTodo,reasonCommentBlockNest,@Spell
syn region reasonCommentBlockDoc matchgroup=reasonCommentBlockDoc start="/\*\%(!\|\*[*/]\@!\)" end="\*/" contains=reasonTodo,reasonCommentBlockDocNest,@Spell
syn region reasonCommentBlockNest matchgroup=reasonCommentBlock start="/\*" end="\*/" contains=reasonTodo,reasonCommentBlockNest,@Spell contained transparent
syn region reasonCommentBlockDocNest matchgroup=reasonCommentBlockDoc start="/\*" end="\*/" contains=reasonTodo,reasonCommentBlockDocNest,@Spell contained transparent
" FIXME: this is a really ugly and not fully correct implementation. Most
" importantly, a case like ``/* */*`` should have the final ``*`` not being in
" a comment, but in practice at present it leaves comments open two levels
" deep. But as long as you stay away from that particular case, I *believe*
" the highlighting is correct. Due to the way Vim's syntax engine works
" (greedy for start matches, unlike Zust's tokeniser which is searching for
" the earliest-starting match, start or end), I believe this cannot be solved.
" Oh you who would fix it, don't bother with things like duplicating the Block
" rules and putting ``\*\@<!`` at the start of them; it makes it worse, as
" then you must deal with cases like ``/*/**/*/``. And don't try making it
" worse with ``\%(/\@<!\*\)\@<!``, either...

syn keyword reasonTodo contained TODO FIXME XXX NB NOTE

" Folding rules {{{2
" Trivial folding rules to begin with.
" FIXME: use the AST to make really good folding
syn region reasonFoldBraces start="{" end="}" transparent fold
" These mess up the highlighting
" reasonIdentifier,reasonIdentifierPrime,
syntax cluster interpolation contains=reasonTemplateString,reasonCommentLine,reasonCommentBlock,reasonMultilineString,reasonString,reasonSelf,reasonBoolean,reasonType,reasonStorage,reasonAssert,reasonFailwith,reasonOperator,reasonConditional,reasonNumber,reasonCharacter,reasonConstructor,labelArgument,labelArgumentPunned,reasonCapsIdent,reasonFloat,reasonModPath,reasonDecNumber,reasonHexNumber,reasonOctNumber,reasonBinNumber,reasonArrowCharacter


" Default highlighting {{{1
hi def link labelArgument Special
hi def link labelArgumentPunned Special
hi def link reasonDecNumber reasonNumber
hi def link reasonHexNumber reasonNumber
hi def link reasonOctNumber reasonNumber
hi def link reasonBinNumber reasonNumber
hi def link reasonIdentifierPrime reasonIdentifier

hi def link reasonEscape Special
hi def link reasonEscapeUnicode reasonEscape
hi def link reasonEscapeError Error
hi def link reasonStringContinuation Special
hi def link reasonString String
hi def link reasonMultilineString String
hi def link reasonTemplateString String


hi def link reasonCharacterInvalid Error
hi def link reasonCharacterInvalidUnicode reasonCharacterInvalid
hi def link reasonCharacter Character
hi def link reasonNumber Number
hi def link reasonBoolean Boolean
hi def link reasonEnum reasonType
hi def link reasonConstructor Constant
hi def link reasonModPath Include
hi def link reasonConstant Constant
hi def link reasonSelf Constant
hi def link reasonFloat Float
hi def link reasonArrowCharacter reasonOperator
hi def link reasonOperator Keyword
hi def link reasonKeyword Keyword
hi def link reasonConditional Conditional
hi def link reasonIdentifier Identifier
hi def link reasonCapsIdent reasonIdentifier
hi def link reasonFunction Function
hi def link reasonFuncName Function
hi def link reasonShebang Comment
hi def link reasonCommentLine Comment
" hi def link reasonCommentLineDoc Comment
hi def link reasonCommentBlock Comment
hi def link reasonCommentBlockDoc Comment
hi def link reasonAssert Precondit
hi def link reasonFailwith PreCondit
hi def link reasonType Type
hi def link reasonTodo Todo
hi def link reasonAttribute PreProc
hi def link reasonStorage Keyword
hi def link reasonObsoleteStorage Error

hi def link reasonTemplateBraces Noise
hi def link reasonTaggedTemplate StorageClass


syn sync minlines=200
syn sync maxlines=500

let b:current_syntax = "reason"
72 changes: 72 additions & 0 deletions .config/ghostty/config
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# Background & Foreground Colors
background = #24273A
foreground = #CAD3F5

# Selection Colors
selection-background = #24273A
selection-foreground = #F4DBD6

# Cursor Colors
cursor-color = #F4DBD6
cursor-text = #24273A
# Black
palette = 0=#494D64
palette = 8=#5B6078

# Red
palette = 1=#ED8796
palette = 9=#ED8796

# Green
palette = 2=#A6DA95
palette = 10=#A6DA95

# Yellow
palette = 3=#EED49F
palette = 11=#EED49F

# Blue
palette = 4=#8AADF4
palette = 12=#8AADF4

# Magenta
palette = 5=#F5BDE6
palette = 13=#F5BDE6

# Cyan
palette = 6=#8BD5CA
palette = 14=#8BD5CA

# White
palette = 7=#B8C0E0
palette = 15=#A5ADCB

# Font family
font-family = JetBrains Mono

# |>
# Font size
font-size = 22

# Opacity of split windows
unfocused-split-opacity = 0.97

# Cursor style
cursor-style-blink = true

# Clipboard settings
clipboard-read = allow
clipboard-write = allow

# Allow option to work as alt on macos
macos-option-as-alt = true

# Always show ghostty as the title
title = ghostty

# Window size
window-width = 90
window-height = 30

window-padding-balance = true
window-padding-x = 0
File renamed without changes.
Binary file added .config/kitty/kitty.app.icns
Binary file not shown.
8 changes: 5 additions & 3 deletions .config/kitty/kitty.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,17 @@
# Theme
include catppuccin-macchiato-theme.conf

/**
# Font
font_family DankMono Nerd Font
font_size 20
font_family JetBrains Mono
# bold_italic_font DankMono Nerd Font Italic
font_size 22

# Allow option to work as alt on macos
macos_option_as_alt yes

# Fix bold nerdfonts on osx
text_composition_strategy legacy
text_composition_strategy legacy

# Configure vim-kitty-navigator
allow_remote_control yes
Expand Down
47 changes: 47 additions & 0 deletions .config/lazy-lock.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
{
"Comment.nvim": { "branch": "master", "commit": "0236521ea582747b58869cb72f70ccfa967d2e89" },
"LuaSnip": { "branch": "master", "commit": "2463d687fe704b76eb0aa3bb34e95f69a5bb0362" },
"cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" },
"cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" },
"copilot-cmp": { "branch": "master", "commit": "72fbaa03695779f8349be3ac54fa8bd77eed3ee3" },
"copilot.lua": { "branch": "master", "commit": "858bbfa6fa81c88fb1f64107d7981f1658619e0a" },
"dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" },
"fidget.nvim": { "branch": "main", "commit": "0ba1e16d07627532b6cae915cc992ecac249fb97" },
"friendly-snippets": { "branch": "main", "commit": "53d3df271d031c405255e99410628c26a8f0d2b0" },
"gitsigns.nvim": { "branch": "main", "commit": "d195f0c35ced5174d3ecce1c4c8ebb3b5bc23fa9" },
"harpoon": { "branch": "master", "commit": "ccae1b9bec717ae284906b0bf83d720e59d12b91" },
"indent-blankline.nvim": { "branch": "master", "commit": "5da5546947f3125dfd6aa85ab21074dc83f776d5" },
"lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" },
"lspkind.nvim": { "branch": "master", "commit": "7f26cf5e27e2bd910ce0ea00c514da2bf97423b8" },
"lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "56e435e09f8729af2d41973e81a0db440f8fe9c9" },
"mason.nvim": { "branch": "main", "commit": "a09da6ac634926a299dd439da08bdb547a8ca011" },
"neodev.nvim": { "branch": "main", "commit": "7cb4f7f29c6bf6f1d21a37f6dd6d12ba64266b09" },
"none-ls.nvim": { "branch": "main", "commit": "e7382de51b4cf629e56f1fa18192e716e5ba8145" },
"nvim": { "branch": "main", "commit": "b901cf144573b293b6cefeb1ac8c97d5d239ee7a" },
"nvim-autopairs": { "branch": "master", "commit": "9fd41181693dd4106b3e414a822bb6569924de81" },
"nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" },
"nvim-lspconfig": { "branch": "master", "commit": "0d9e870d01894c592d7ea93cfe0fa451916d9a7f" },
"nvim-notify": { "branch": "master", "commit": "ebcdd8219e2a2cbc0a4bef68002f6867f1fde269" },
"nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" },
"nvim-tmux-navigation": { "branch": "main", "commit": "d9efffa413a530bdea3783af4fea86be84940283" },
"nvim-treesitter": { "branch": "master", "commit": "e49f1e8ef3e8450a8446cb1f2bbb53c919f60b6d" },
"nvim-treesitter-textobjects": { "branch": "master", "commit": "0e2d5bd4cbe75849a013901555d436a48c6680cb" },
"nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" },
"nvim-ufo": { "branch": "main", "commit": "c6d88523f574024b788f1c3400c5d5b9bb1a0407" },
"nvim-web-devicons": { "branch": "master", "commit": "808627b8d412b2a6b6fc6eed816fec3557198b01" },
"oil.nvim": { "branch": "master", "commit": "523b61430cb7365f8f86609c2ea60e48456bac63" },
"plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" },
"promise-async": { "branch": "main", "commit": "94f6f03c6c1e2aab551aacdf0c1e597a7269abb6" },
"symbols-outline.nvim": { "branch": "master", "commit": "512791925d57a61c545bc303356e8a8f7869763c" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" },
"telescope.nvim": { "branch": "0.1.x", "commit": "d90956833d7c27e73c621a61f20b29fdb7122709" },
"tsc.nvim": { "branch": "main", "commit": "a8f26d3d6a0faf533afb840816a6d9ac6a1fcbea" },
"vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" },
"vim-maximizer": { "branch": "master", "commit": "2e54952fe91e140a2e69f35f22131219fcd9c5f1" },
"vim-surround": { "branch": "master", "commit": "3d188ed2113431cf8dac77be61b842acb64433d9" },
"wilder.nvim": { "branch": "master", "commit": "679f348dc90d80ff9ba0e7c470c40a4d038dcecf" }
}
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ return {
}),
-- sources for autocompletion
sources = cmp.config.sources({
{ name = "copilot" }, -- Copilot suggestions
{ name = "nvim_lsp" }, -- lsp
{ name = "luasnip", max_item_count = 3 }, -- snippets
{ name = "buffer", max_item_count = 5 }, -- text within current buffer
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ return {
require("Comment").setup({
pre_hook = require("ts_context_commentstring.integrations.comment_nvim").create_pre_hook(),
})

local ft = require("Comment.ft")
ft.set("reason", { "//%s", "/*%s*/" })
end,
},
}
Loading

0 comments on commit ebbee80

Please sign in to comment.