Compare commits

..

No commits in common. "46365743da3b0b7f7848cc733e69392446cbc33a" and "61b1bcfa0e766cbc78db8719a3e0bc4e09c678a9" have entirely different histories.

33 changed files with 41 additions and 237 deletions

View File

@ -1,17 +1,17 @@
From 8295005701c85955551b7493922b41085843fbe6 Mon Sep 17 00:00:00 2001
From 2f2ed36df2c55ca60c7074cf80f97cdc6d53f83e Mon Sep 17 00:00:00 2001
From: Alyxia Sother <alyxia@riseup.net>
Date: Sat, 23 Sep 2023 11:16:37 +0200
Date: Mon, 22 May 2023 10:14:07 +0200
Subject: [PATCH] web: build local extensions as well
---
web/buildExtension.js | 44 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
web/buildExtension.js | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)
diff --git a/web/buildExtension.js b/web/buildExtension.js
index 206408c..8ed3312 100644
index 206408c..4984ab2 100644
--- a/web/buildExtension.js
+++ b/web/buildExtension.js
@@ -1,7 +1,46 @@
@@ -1,7 +1,37 @@
+const fs = require("fs");
+const os = require("os");
+const path = require("path");
@ -19,19 +19,10 @@ index 206408c..8ed3312 100644
process.env.BUILD_TYPE = "extension";
const config = require("./webpack.config.js");
+const platform = os.platform();
+let dataDir;
+switch (platform) {
+ case "linux":
+ dataDir = path.join(os.homedir(), ".config/hh3");
+ break;
+ case "darwin":
+ dataDir = path.join(os.homedir(), "Library/ApplicationSupport/hh3");
+ break;
+}
+if (!dataDir) throw new Error("No dataDir could be inferred! Aborting!");
+
+const PATH_TO_EXTS = path.join(dataDir, "ext");
+const PATH_TO_EXTS = path.join(
+ os.homedir(),
+ "Library/ApplicationSupport/hh3/ext"
+);
+const HH_EXT_DIR = path.join(__dirname, "../ext");
+let exts = fs.readdirSync(PATH_TO_EXTS);
+exts = exts.filter((e) => e !== ".git");
@ -58,7 +49,7 @@ index 206408c..8ed3312 100644
webpack.webpack(config, (err, stats) => {
if (!stats?.compilation) {
console.log(err);
@@ -21,5 +60,10 @@ webpack.webpack(config, (err, stats) => {
@@ -21,5 +51,10 @@ webpack.webpack(config, (err, stats) => {
})
);
}
@ -70,5 +61,5 @@ index 206408c..8ed3312 100644
}
});
--
2.42.0
2.37.1 (Apple Git-137.1)

View File

@ -1,8 +1,8 @@
diff --git a/web/buildExtension.js b/web/buildExtension.js
index 206408c..8ed3312 100644
index 206408c..4984ab2 100644
--- a/web/buildExtension.js
+++ b/web/buildExtension.js
@@ -1,7 +1,46 @@
@@ -1,7 +1,37 @@
+const fs = require("fs");
+const os = require("os");
+const path = require("path");
@ -10,19 +10,10 @@ index 206408c..8ed3312 100644
process.env.BUILD_TYPE = "extension";
const config = require("./webpack.config.js");
+const platform = os.platform();
+let dataDir;
+switch (platform) {
+ case "linux":
+ dataDir = path.join(os.homedir(), ".config/hh3");
+ break;
+ case "darwin":
+ dataDir = path.join(os.homedir(), "Library/ApplicationSupport/hh3");
+ break;
+}
+if (!dataDir) throw new Error("No dataDir could be inferred! Aborting!");
+
+const PATH_TO_EXTS = path.join(dataDir, "ext");
+const PATH_TO_EXTS = path.join(
+ os.homedir(),
+ "Library/ApplicationSupport/hh3/ext"
+);
+const HH_EXT_DIR = path.join(__dirname, "../ext");
+let exts = fs.readdirSync(PATH_TO_EXTS);
+exts = exts.filter((e) => e !== ".git");
@ -49,7 +40,7 @@ index 206408c..8ed3312 100644
webpack.webpack(config, (err, stats) => {
if (!stats?.compilation) {
console.log(err);
@@ -21,5 +60,10 @@ webpack.webpack(config, (err, stats) => {
@@ -21,5 +51,10 @@ webpack.webpack(config, (err, stats) => {
})
);
}

View File

@ -25,7 +25,6 @@ overrides:
extends:
- eslint-config-dmitmel/presets/typescript-addon
parserOptions:
ecmaVersion: 2020
project: 'tsconfig.json'
sourceType: module
rules:

View File

@ -1,14 +1,7 @@
export {};
import { EventEmitter } from 'events';
declare global {
const hh: {
emitter: EventEmitter;
constants: Record<string, string> & { categories: Record<string, string> };
// TODO: Maybe turn this into something that, based on the moduleName, can
// fetch an ext's actual config type and return that instead.
getModuleOptions: (moduleName: string) => Record<string, any>;
};
const wreq: (module: string) => any;
}

@ -1 +1 @@
Subproject commit 971208fe9c71044e35d2d2ef0360a499966517a0
Subproject commit fb8942c077d9f5974f02040e7369f29ef2a3b762

View File

@ -7,11 +7,11 @@
]
},
"locked": {
"lastModified": 1704277720,
"narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=",
"lastModified": 1687691275,
"narHash": "sha256-VVywT8ubStvDPF5TscDBokT3T0l3zsOzCW056noh5zc=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4",
"rev": "25ae710ba3cd448c5d5678788d37f3d149378bc0",
"type": "github"
},
"original": {
@ -23,11 +23,11 @@
"dotfiles": {
"flake": false,
"locked": {
"lastModified": 1702297498,
"narHash": "sha256-wBeX8mOuPwXzHmPSTwcafa3ioV1r1biBaM4Pz9TQezw=",
"lastModified": 1687268328,
"narHash": "sha256-TS4xL8LIZHApLsLZmhgfk9mUDkTwbFUIyZ6Hze4Uyvc=",
"ref": "refs/heads/master",
"rev": "be29a97b84dbb54e125dac19df3478464b7f76ca",
"revCount": 456,
"rev": "e7576c13c466b618ba2cd26b0ae67dd91389633b",
"revCount": 393,
"submodules": true,
"type": "git",
"url": "https://github.com/keanuplayz/dotfiles"
@ -45,11 +45,11 @@
]
},
"locked": {
"lastModified": 1702195668,
"narHash": "sha256-Lxmjez0nfNBptdqV5GsXKm7Bb7swjGsrxiLxWJu0tL8=",
"lastModified": 1687647567,
"narHash": "sha256-Ua90LZYJO7/7KW/KK/AqijhIekd+wxPwbVKXuBYzJeQ=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "33110fb3c7fe6a94b98b641866a5eddb64b7c23f",
"rev": "6ca1e16eb3016c94b7ac16699e1d4158bd4e39a4",
"type": "github"
},
"original": {
@ -61,11 +61,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1705033721,
"narHash": "sha256-K5eJHmL1/kev6WuqyqqbS1cdNnSidIZ3jeqJ7GbrYnQ=",
"lastModified": 1687762512,
"narHash": "sha256-2SqEYe/aFyUWDTD3DNzSUt718OspYg7pZpLk+tG9tCw=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "a1982c92d8980a0114372973cbdfe0a307f1bdea",
"rev": "a5173c3819f44726a6aed01ec0bca6221b162a1c",
"type": "github"
},
"original": {

View File

@ -1,4 +1,4 @@
{ pkgs, lib, dotfiles, ... }:
{ pkgs, specialArgs, lib, dotfiles, ... }:
with lib;
let
@ -30,6 +30,7 @@ let
jq
kubectl
kubelogin-oidc
lua-language-server
mosh
nixpkgs-fmt
pandoc
@ -37,7 +38,6 @@ let
sops
stylua
texlive.combined.scheme-small
typst
vim
wget
@ -51,17 +51,12 @@ let
languages = [
crystal
dhall
dhall-json
dhall-lsp-server
deno
dotnet-sdk
go
jdk
kotlin
kotlin-language-server
lua-language-server
nil
nodejs_20
python2
ruby_3_1
sbcl
shards
@ -70,6 +65,7 @@ let
programs = [
rectangle
slack
tailscale
];
@ -81,13 +77,7 @@ let
nerdfonts
];
python = with python311Packages; [
colorama
psutil
distro
];
everything = system ++ base ++ languages ++ programs ++ multimedia ++ fonts ++ python;
everything = system ++ base ++ languages ++ programs ++ multimedia ++ fonts;
};
# Old solution kept for posterity {{{
@ -150,9 +140,6 @@ in
# Absolutely proprietary.
nixpkgs.config.allowUnfree = true;
nixpkgs.config.permittedInsecurePackages = [
"python-2.7.18.6"
];
# Make sure the nix daemon always runs
services.nix-daemon.enable = true;
@ -164,9 +151,6 @@ in
# you'll need to enable this so nix-darwin creates a zshrc sourcing needed environment changes
programs.zsh.enable = true;
# tailscaled isn't automatically registered as a service that should run on installation.
services.tailscale.enable = true;
# Make sure to set the correct values, or everything will break! (in reality,
# it will just not build)
users.users.alyxia = {
@ -211,20 +195,14 @@ in
"drud/ddev"
"homebrew/cask"
"homebrew/cask-versions"
"int128/kubelogin"
];
# Please do not the brew.
brews = [
"bear"
"composer"
"croc"
"ddev"
"dotnet"
"gradle"
"kubelogin"
"mkcert"
"nss"
"pinentry-mac"
"pkg-config"
"sdl2"
@ -252,30 +230,21 @@ in
"discord-ptb"
"docker"
"firefox"
"firefox-developer-edition"
"goland"
"google-chrome"
"intellij-idea"
"itch"
"iterm2"
"lens"
"obs"
"orbstack"
"phpstorm"
"plexamp"
"raycast"
"rider"
"rubymine"
"sequel-ace"
"shottr"
"slack"
"spotify"
"steam"
"texifier"
"thunderbird"
"transmit"
"visual-studio-code"
"wine-stable"
];
};
}

View File

@ -12,10 +12,6 @@
signByDefault = true;
};
ignores = [
".DS_Store"
];
delta = {
enable = true;
options = {

View File

@ -17,20 +17,13 @@
filetypes = [ "nix" ];
rootPatterns = [ "flake.nix" ];
"settings.nil" = {
"formatting.command" = [ "nixpkgs-fmt" ];
"formatting.command" = ["nixpkgs-fmt"];
};
};
"go.goPlsOptions" = {
completion = true;
completeUnimported = true;
};
rescript = {
enable = true;
command = "rescript-language-server";
args = [ "--node-ipc" ];
filetypes = [ "rescript" ];
rootPatterns = [ "rescript.json" "bsconfig.json" ];
};
};
};
};

View File

@ -13,15 +13,6 @@
export PATH="$PATH:$HOME/.npm-packages/bin"
export FRENYARD_SCALE=2.40
export RETHINK_API="https://rethink.alyxia.dev"
export KUBECONFIG="$HOME/.kube/config.yaml"
function violent-update() {
# <https://github.com/adryd325/dotfiles/blob/c52d10f0cb4b54ee46e2ac5b01b8be9f8d57973d/install.sh#L17>
sudo -v; while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
cd "$HOME/.dotfiles/nix";
sudo nix-channel --update && nix-channel --update;
sudo nix-env -u;
}
'';
};
}

View File

@ -1 +0,0 @@
# WIP!!!

View File

@ -1,12 +0,0 @@
local init_modules = {
-- "aly.plugins",
"aly.options"
}
for _, module in ipairs(init_modules) do
local ok, err = pcall(require, module)
if not ok then
error("Error loading " .. module .. "\n\n" .. err)
end
end

View File

@ -1,12 +0,0 @@
print("yes")
local options = {
termguicolors = true, -- how do I even use the editor without this?
}
for o, _ in pairs(options) do
vim.opt[o] = _
end
vim.cmd("filetype plugin indent on")
vim.cmd("syntax enable")

View File

@ -1,68 +0,0 @@
return {
-- the colorscheme should be available when starting Neovim
{
"folke/tokyonight.nvim",
lazy = false, -- make sure we load this during startup if it is your main colorscheme
priority = 1000, -- make sure to load this before all the other start plugins
config = function()
-- load the colorscheme here
vim.cmd([[colorscheme tokyonight]])
end,
},
{
"neovim/nvim-lspconfig",
event = { "BufReadPre", "BufNewFile" },
dependencies = {
{ "folke/neoconf.nvim", cmd = "Neoconf", config = false, dependencies = { "nvim-lspconfig" } },
{ "folke/neodev.nvim", opts = {} },
"williamboman/mason.nvim",
"williamboman/mason-lspconfig.nvim",
{ "j-hui/fidget.nvim", tag = "legacy", opts = {} },
"hrsh7th/cmp-nvim-lsp",
},
config = function() end,
opts = {
servers = {
lua_ls = {}
}
}
},
{
"hrsh7th/nvim-cmp",
event = "InsertEnter",
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"hrsh7th/cmp-buffer",
"hrsh7th/cmp-path",
"L3MON4D3/LuaSnip",
"saadparwaiz1/cmp_luasnip",
},
opts = function()
local cmp = require("cmp")
return {
sources = cmp.config.sources({
{ name = "nvim_lsp" },
{ name = "luasnip" },
{ name = "buffer" },
{ name = "path" },
}),
}
end
},
{
"windwp/nvim-autopairs",
dependencies = { "hrsh7th/nvim-cmp" },
config = function()
require("nvim-autopairs").setup {}
local cmp_autopairs = require("nvim-autopairs.completion.cmp")
local cmp = require("cmp")
cmp.event:on(
'confirm_done',
cmp_autopairs.on_confirm_done()
)
end,
},
{ "nvim-tree/nvim-web-devicons", lazy = true },
{ "stevearc/dressing.nvim", event = "VeryLazy" },
}

View File

@ -46,7 +46,6 @@ let s:plug = funcref('dotfiles#plugman#register')
call s:plug('tpope/vim-projectionist')
call s:plug('tpope/vim-dispatch')
" }}}
call s:plug('rescript-lang/vim-rescript')
" }}}
" coc {{{
@ -55,10 +54,6 @@ let s:plug = funcref('dotfiles#plugman#register')
endif
" }}}
" mini.nvim {{{
call s:plug('echasnovski/mini.pairs')
" }}}
" Misc {{{
if has('nvim')
call s:plug('andweeb/presence.nvim')

View File

@ -5,15 +5,6 @@ let &runtimepath = g:k_nvim_dotfiles_dir.','.&runtimepath.','.g:k_nvim_dotfiles_
let g:vim_ide = 1
let g:dotfiles_rainbow_indent_opacity = 0.5
" Inhibited plugins {{{
" I'd love to use dotfiles#plugman#inhibit in my plugins-list.vim but by that
" point it is already too late.
let g:dotfiles#plugman#inhibited_plugins = {}
" Does not do its job properly anymore, I'm afraid.
let g:dotfiles#plugman#inhibited_plugins["delimitMate"] = 1
" }}}
source <sfile>:p:h/../dmitmel-dotfiles/nvim/init.vim
if has('nvim')

View File

@ -9,7 +9,7 @@ nnoremap <C-t> :NERDTreeToggle<CR>
nmap <silent> <F3> <Plug>(coc-codeaction-line)
xmap <silent> <F3> <Plug>(coc-codeaction-selected)
inoremap <expr> <C-CR> coc#pum#visible() ? coc#pum#confirm() : "\<CR>"
inoremap <expr> <cr> coc#pum#visible() ? coc#_select_confirm() : "\<CR>"
inoremap <silent><expr> <TAB>
\ coc#pum#visible() ? coc#pum#next(1):

View File

@ -1,6 +0,0 @@
local ok, mini_pairs = pcall(require, "mini.pairs")
if not ok then
return
end
mini_pairs.setup()

View File

@ -1,7 +1,6 @@
alias welcome="welcome --extra-logos-dir $K_ZSH_DOTFILES/../script-resources/welcome/logos"
alias markdown2htmldoc="$K_ZSH_DOTFILES/../scripts/markdown2htmldoc"
alias mediawiki-preview="$K_ZSH_DOTFILES/../scripts/mediawiki-preview"
alias sail='[ -f sail ] && sh sail || sh vendor/bin/sail'
if (( _is_macos )); then
if command_exists exa; then

View File

@ -43,9 +43,4 @@ _plugin project 'https://git.sr.ht/~keanucode/scripts/blob/master/project/projec
_plugin keybase-compl 'https://raw.githubusercontent.com/fnoris/keybase-zsh-completion/master/_keybase' from=url \
after_load='plugin-cfg-path fpath prepend ""'
if command_exists pnpm-shell-completion; then
_plugin pnpm-compl "https://raw.githubusercontent.com/g-plane/pnpm-shell-completion/main/pnpm-shell-completion.plugin.zsh" from=url \
after_load='plugin-cfg-path fpath prepend ""'
fi
# }}}