diff --git a/flake/dev/flake.lock b/flake/dev/flake.lock index 95b87c203..0a8289fd4 100644 --- a/flake/dev/flake.lock +++ b/flake/dev/flake.lock @@ -157,11 +157,11 @@ ] }, "locked": { - "lastModified": 1758997081, - "narHash": "sha256-c4SbPEbR9yP5erODj4niMO7N+2ONEoGnWnt5hauAHRg=", + "lastModified": 1760809591, + "narHash": "sha256-OxGcFcQdfOK8veZkPdQuqXIotFYiy4sBQB58dMNLeHY=", "owner": "nix-community", "repo": "home-manager", - "rev": "26ace005b720b7628fdf2d4923e7feecdd1631c4", + "rev": "870883ba11ba1c84f756c0c1f9fa74cdb2a16c1e", "type": "github" }, "original": { diff --git a/generated/all-maintainers.nix b/generated/all-maintainers.nix index 6411db9e0..55ea28e25 100644 --- a/generated/all-maintainers.nix +++ b/generated/all-maintainers.nix @@ -63,6 +63,12 @@ githubId = 150545; name = "Igor Rzegocki"; }; + arunoruto = { + email = "mirza.arnaut45@gmail.com"; + github = "arunoruto"; + githubId = 21687187; + name = "Mirza Arnaut"; + }; awwpotato = { email = "awwpotato@voidq.com"; github = "awwpotato"; diff --git a/modules/opencode/hm.nix b/modules/opencode/hm.nix new file mode 100644 index 000000000..bb6034581 --- /dev/null +++ b/modules/opencode/hm.nix @@ -0,0 +1,223 @@ +{ mkTarget, ... }: +mkTarget { + name = "opencode"; + humanName = "OpenCode"; + + configElements = + { colors }: + { + programs.opencode = + let + theme = "stylix"; + in + { + settings = { inherit theme; }; + themes.${theme} = { + theme = { + accent = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + background = { + dark = colors.withHashtag.base00; + light = colors.withHashtag.base06; + }; + backgroundElement = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base04; + }; + backgroundPanel = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + border = { + dark = colors.withHashtag.base02; + light = colors.withHashtag.base03; + }; + borderActive = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base02; + }; + borderSubtle = { + dark = colors.withHashtag.base02; + light = colors.withHashtag.base03; + }; + diffAdded = { + dark = colors.withHashtag.base0B; + light = colors.withHashtag.base0B; + }; + diffAddedBg = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + diffAddedLineNumberBg = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + diffContext = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base03; + }; + diffContextBg = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + diffHighlightAdded = { + dark = colors.withHashtag.base0B; + light = colors.withHashtag.base0B; + }; + diffHighlightRemoved = { + dark = colors.withHashtag.base08; + light = colors.withHashtag.base08; + }; + diffHunkHeader = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base03; + }; + diffLineNumber = { + dark = colors.withHashtag.base02; + light = colors.withHashtag.base04; + }; + diffRemoved = { + dark = colors.withHashtag.base08; + light = colors.withHashtag.base08; + }; + diffRemovedBg = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + diffRemovedLineNumberBg = { + dark = colors.withHashtag.base01; + light = colors.withHashtag.base05; + }; + error = { + dark = colors.withHashtag.base08; + light = colors.withHashtag.base08; + }; + info = { + dark = colors.withHashtag.base0C; + light = colors.withHashtag.base0F; + }; + markdownBlockQuote = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base03; + }; + markdownCode = { + dark = colors.withHashtag.base0B; + light = colors.withHashtag.base0B; + }; + markdownCodeBlock = { + dark = colors.withHashtag.base04; + light = colors.withHashtag.base00; + }; + markdownEmph = { + dark = colors.withHashtag.base09; + light = colors.withHashtag.base09; + }; + markdownHeading = { + dark = colors.withHashtag.base0C; + light = colors.withHashtag.base0F; + }; + markdownHorizontalRule = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base03; + }; + markdownImage = { + dark = colors.withHashtag.base0D; + light = colors.withHashtag.base0D; + }; + markdownImageText = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + markdownLink = { + dark = colors.withHashtag.base0D; + light = colors.withHashtag.base0D; + }; + markdownLinkText = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + markdownListEnumeration = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + markdownListItem = { + dark = colors.withHashtag.base0C; + light = colors.withHashtag.base0F; + }; + markdownStrong = { + dark = colors.withHashtag.base0A; + light = colors.withHashtag.base0A; + }; + markdownText = { + dark = colors.withHashtag.base04; + light = colors.withHashtag.base00; + }; + primary = { + dark = colors.withHashtag.base0C; + light = colors.withHashtag.base0F; + }; + secondary = { + dark = colors.withHashtag.base0D; + light = colors.withHashtag.base0D; + }; + success = { + dark = colors.withHashtag.base0B; + light = colors.withHashtag.base0B; + }; + syntaxComment = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base03; + }; + syntaxFunction = { + dark = colors.withHashtag.base0C; + light = colors.withHashtag.base0C; + }; + syntaxKeyword = { + dark = colors.withHashtag.base0D; + + light = colors.withHashtag.base0D; + + }; + syntaxNumber = { + dark = colors.withHashtag.base0E; + light = colors.withHashtag.base0E; + }; + syntaxOperator = { + dark = colors.withHashtag.base0D; + light = colors.withHashtag.base0D; + }; + syntaxPunctuation = { + dark = colors.withHashtag.base04; + light = colors.withHashtag.base00; + }; + syntaxString = { + dark = colors.withHashtag.base0B; + light = colors.withHashtag.base0B; + }; + syntaxType = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + syntaxVariable = { + dark = colors.withHashtag.base07; + light = colors.withHashtag.base07; + }; + text = { + dark = colors.withHashtag.base04; + light = colors.withHashtag.base00; + }; + textMuted = { + dark = colors.withHashtag.base03; + light = colors.withHashtag.base01; + }; + warning = { + dark = colors.withHashtag.base09; + light = colors.withHashtag.base09; + }; + }; + }; + }; + }; +} diff --git a/modules/opencode/meta.nix b/modules/opencode/meta.nix new file mode 100644 index 000000000..0c69b767a --- /dev/null +++ b/modules/opencode/meta.nix @@ -0,0 +1,6 @@ +{ lib, ... }: +{ + name = "OpenCode"; + homepage = "https://opencode.ai"; + maintainers = [ lib.maintainers.arunoruto ]; +} diff --git a/modules/opencode/testbeds/opencode.nix b/modules/opencode/testbeds/opencode.nix new file mode 100644 index 000000000..d2f350abf --- /dev/null +++ b/modules/opencode/testbeds/opencode.nix @@ -0,0 +1,11 @@ +{ lib, pkgs, ... }: +{ + stylix.testbed.ui.command = { + text = lib.getExe pkgs.opencode; + useTerminal = true; + }; + + home-manager.sharedModules = lib.singleton { + programs.opencode.enable = true; + }; +}