mirror of
https://github.com/genebean/dots.git
synced 2026-03-27 01:17:42 -04:00
Pull oh-my-posh theme from its own repository
With help from others, I can now pull the theme file from the repo it lives in instead of embedding it here!
This commit is contained in:
parent
badf0988a2
commit
180b8494ba
4 changed files with 27 additions and 167 deletions
17
flake.lock
generated
17
flake.lock
generated
|
|
@ -35,6 +35,22 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"genebean-omp-themes": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1694629194,
|
||||
"narHash": "sha256-k1HqpsW5buBGe3rgugQvoKw5nPu/zBWiT8blb5eHc0w=",
|
||||
"owner": "genebean",
|
||||
"repo": "my-oh-my-posh-themes",
|
||||
"rev": "eb6ba507c2f37accc926c65bac1b88293a71eb9c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "genebean",
|
||||
"repo": "my-oh-my-posh-themes",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
|
@ -160,6 +176,7 @@
|
|||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"genebean-omp-themes": "genebean-omp-themes",
|
||||
"home-manager": "home-manager",
|
||||
"nix-darwin": "nix-darwin",
|
||||
"nix-homebrew": "nix-homebrew",
|
||||
|
|
|
|||
|
|
@ -20,8 +20,14 @@
|
|||
# Manage Homebrew itself
|
||||
nix-homebrew.url = "github:zhaofengli-wip/nix-homebrew";
|
||||
|
||||
# My oh-my-posh theme
|
||||
genebean-omp-themes = {
|
||||
url = "github:genebean/my-oh-my-posh-themes";
|
||||
flake = false;
|
||||
};
|
||||
|
||||
}; # end inputs
|
||||
outputs = { self, nixpkgs, nix-darwin, home-manager, nix-homebrew, ... }: {
|
||||
outputs = { self, nixpkgs, nix-darwin, home-manager, nix-homebrew, genebean-omp-themes, ... }: {
|
||||
nixosConfigurations = let
|
||||
user = "gene";
|
||||
in {
|
||||
|
|
@ -79,6 +85,7 @@
|
|||
users.${user}.imports = [
|
||||
./modules/home-manager
|
||||
];
|
||||
extraSpecialArgs = { inherit genebean-omp-themes; };
|
||||
};
|
||||
}
|
||||
]; # end modules
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, ... }: {
|
||||
{ pkgs, genebean-omp-themes, ... }: {
|
||||
home.stateVersion = "23.11";
|
||||
home.packages = with pkgs; [
|
||||
colordiff
|
||||
|
|
@ -51,7 +51,7 @@
|
|||
oh-my-posh = {
|
||||
enable = true;
|
||||
enableZshIntegration = true;
|
||||
settings = builtins.fromJSON (builtins.unsafeDiscardStringContext (builtins.readFile ./files/beanbag.omp.json));
|
||||
settings = builtins.fromJSON (builtins.unsafeDiscardStringContext (builtins.readFile (genebean-omp-themes + "/beanbag.omp.json")));
|
||||
};
|
||||
vim = {
|
||||
enable = true;
|
||||
|
|
|
|||
|
|
@ -1,164 +0,0 @@
|
|||
{
|
||||
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
|
||||
"version": 2,
|
||||
"final_space": true,
|
||||
"palette": {
|
||||
"line-connector": "#00ff00",
|
||||
"hostname": "#62c0ff",
|
||||
"pwd": "#ffff00",
|
||||
"git-fg-clean": "#62c0ff",
|
||||
"git-fg-changed": "#6287ff",
|
||||
"git-fg-ahead-and-behind": "#7f62ff",
|
||||
"git-fg-ahead": "#9962ff",
|
||||
"git-fg-behind": "#c062ff",
|
||||
"svn-fg-clean": "#62c0ff",
|
||||
"svn-fg-changed": "#6287ff",
|
||||
"kubectl-fg": "#62c0ff",
|
||||
"kubectl-bg": "transparent",
|
||||
"status-fg-okay": "#00ff00",
|
||||
"status-fg-error": "#D81E5B",
|
||||
"tooltip-fg": "#E0DEF4",
|
||||
"tooltip-az-bg": "#4B95E9",
|
||||
"secondary-fg": "#00ff00",
|
||||
"orange-text": "#ff8800"
|
||||
},
|
||||
"blocks": [
|
||||
{
|
||||
"type": "prompt",
|
||||
"alignment": "left",
|
||||
"segments": [
|
||||
{
|
||||
"type": "text",
|
||||
"style": "plain",
|
||||
"foreground": "p:line-connector",
|
||||
"template": "\u2554"
|
||||
},
|
||||
{
|
||||
"type": "text",
|
||||
"style": "plain",
|
||||
"template": " \u2615 "
|
||||
},
|
||||
{
|
||||
"type": "session",
|
||||
"style": "plain",
|
||||
"foreground": "p:hostname",
|
||||
"template": " {{ (split \".\" .HostName)._0 }}"
|
||||
},
|
||||
{
|
||||
"type": "os",
|
||||
"style": "plain",
|
||||
"template": "{{ if .WSL }}<p:hostname>(</>WSL {{.Icon}}<p:hostname>)</>{{ end }}"
|
||||
},
|
||||
{
|
||||
"type": "path",
|
||||
"style": "plain",
|
||||
"foreground": "p:pwd",
|
||||
"template": " {{ path .Path .Location }}",
|
||||
"properties": {
|
||||
"folder_separator_icon": "/",
|
||||
"style": "full"
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "kubectl",
|
||||
"style": "powerline",
|
||||
"powerline_symbol": "\uE0B0",
|
||||
"foreground": "p:kubectl-fg",
|
||||
"background": "p:kubectl-bg",
|
||||
"template": " <p:orange-text>(</>\uFD31 {{.Context}}{{if .Namespace}} :: {{.Namespace}}{{end}}<p:orange-text>)</>"
|
||||
},
|
||||
{
|
||||
"type": "git",
|
||||
"style": "plain",
|
||||
"foreground": "p:git-fg-clean",
|
||||
"foreground_templates": [
|
||||
"{{ if or (.Working.Changed) (.Staging.Changed) }}p:git-fg-changed{{ end }}",
|
||||
"{{ if and (gt .Ahead 0) (gt .Behind 0) }}p:git-fg-ahead-and-behind{{ end }}",
|
||||
"{{ if gt .Ahead 0 }}p:git-fg-ahead{{ end }}",
|
||||
"{{ if gt .Behind 0 }}p:git-fg-behind{{ end }}"
|
||||
],
|
||||
"template": " <p:orange-text>on</> {{ if .UpstreamURL }}{{ url .UpstreamIcon .UpstreamURL }} {{ end }}{{ url .HEAD .Kraken }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }} \uf044 {{ .Working.String }}{{ end }}{{ if .Staging.Changed }} \uf046 {{ .Staging.String }}{{ end }}",
|
||||
"properties": {
|
||||
"branch_max_length": 25,
|
||||
"fetch_stash_count": true,
|
||||
"fetch_status": true,
|
||||
"fetch_upstream_icon": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "svn",
|
||||
"style": "plain",
|
||||
"foreground": "p:svn-fg-clean",
|
||||
"foreground_templates": [
|
||||
"{{ if (.Working.Changed) }}p:svn-fg-changed{{ end }}"
|
||||
],
|
||||
"template": " <p:orange-text>on svn</> \ue0a0{{.Branch}} r{{.BaseRev}}{{ if .Working.Changed }} \uf044 {{.Working.String}}{{ end }}",
|
||||
"properties": {
|
||||
"fetch_status": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "status",
|
||||
"style": "diamond",
|
||||
"foreground": "p:status-fg-okay",
|
||||
"foreground_templates": [
|
||||
"{{ if gt .Code 0 }}p:status-fg-error{{ end }}"
|
||||
],
|
||||
"template": " (exit code {{ .Code }})",
|
||||
"properties": {
|
||||
"always_enabled": false
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "prompt",
|
||||
"alignment": "left",
|
||||
"newline": true,
|
||||
"segments": [
|
||||
{
|
||||
"foreground": "p:line-connector",
|
||||
"style": "plain",
|
||||
"template": "\u255A\u1405",
|
||||
"type": "text"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"tooltips": [
|
||||
{
|
||||
"type": "aws",
|
||||
"tips": [
|
||||
"aws"
|
||||
],
|
||||
"style": "diamond",
|
||||
"foreground": "p:tooltip-fg",
|
||||
"background": "p:orange-text",
|
||||
"leading_diamond": "\ue0b0",
|
||||
"trailing_diamond": "\ue0b4",
|
||||
"template": " \ue7ad {{ .Profile }}{{ if .Region }}@{{ .Region }}{{ end }} ",
|
||||
"properties": {
|
||||
"display_default": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"type": "az",
|
||||
"tips": [
|
||||
"az"
|
||||
],
|
||||
"style": "diamond",
|
||||
"foreground": "p:tooltip-fg",
|
||||
"background": "p:tooltip-az-bg",
|
||||
"leading_diamond": "\ue0b0",
|
||||
"trailing_diamond": "\ue0b4",
|
||||
"template": " \uebd8 {{ .Name }} ",
|
||||
"properties": {
|
||||
"display_default": true
|
||||
}
|
||||
}
|
||||
],
|
||||
"secondary_prompt": {
|
||||
"foreground": "p:secondary-fg",
|
||||
"template": " "
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue