add: added swaytreesave
mod: adjusted music-presence, vintage-story packages
This commit is contained in:
71
.gitea/workflows/publish-attic.yaml
Normal file
71
.gitea/workflows/publish-attic.yaml
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
name: Publish packages to Attic
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
env:
|
||||||
|
ATTIC_SERVER: ${{ secrets.ATTIC_SERVER }}
|
||||||
|
ATTIC_CACHE: ${{ secrets.ATTIC_CACHE }}
|
||||||
|
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Install Nix
|
||||||
|
uses: DeterminateSystems/nix-installer-action@v18
|
||||||
|
continue-on-error: true
|
||||||
|
|
||||||
|
- name: Install Attic client
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
if command -v attic >/dev/null 2>&1; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
nix profile install --accept-flake-config nixpkgs#attic-client
|
||||||
|
echo "$HOME/.nix-profile/bin" >> "$GITHUB_PATH"
|
||||||
|
|
||||||
|
- name: Configure Attic
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
: "${ATTIC_SERVER:?Set the ATTIC_SERVER secret to your Attic API base URL}"
|
||||||
|
: "${ATTIC_CACHE:?Set the ATTIC_CACHE secret to the destination cache name}"
|
||||||
|
: "${ATTIC_TOKEN:?Set the ATTIC_TOKEN secret to a token with push access}"
|
||||||
|
|
||||||
|
export PATH="$HOME/.nix-profile/bin:$PATH"
|
||||||
|
|
||||||
|
attic login --set-default ci "$ATTIC_SERVER" "$ATTIC_TOKEN"
|
||||||
|
attic use "$ATTIC_CACHE"
|
||||||
|
|
||||||
|
- name: Build packages
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
|
system="$(nix eval --impure --raw --expr builtins.currentSystem)"
|
||||||
|
|
||||||
|
nix build --accept-flake-config --no-link --print-out-paths -L \
|
||||||
|
".#packages.${system}.sable-web" \
|
||||||
|
".#packages.${system}.musicpresence" \
|
||||||
|
".#packages.${system}.vintage-story" \
|
||||||
|
".#packages.${system}.swaytreesave" \
|
||||||
|
| tee built-paths.txt
|
||||||
|
|
||||||
|
- name: Push packages to Attic
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export PATH="$HOME/.nix-profile/bin:$PATH"
|
||||||
|
xargs -r attic push "$ATTIC_CACHE" < built-paths.txt
|
||||||
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@@ -0,0 +1 @@
|
|||||||
|
result/
|
||||||
117
flake.lock
generated
Normal file
117
flake.lock
generated
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
{
|
||||||
|
"nodes": {
|
||||||
|
"darwin": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1779036909,
|
||||||
|
"narHash": "sha256-zXcwYQGCT6pzinK+1dBB2ekTVtfxGZAapb3Evdcu4fY=",
|
||||||
|
"owner": "LnL7",
|
||||||
|
"repo": "nix-darwin",
|
||||||
|
"rev": "56c666e108467d87d13508936aade6d567f2a501",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "LnL7",
|
||||||
|
"repo": "nix-darwin",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"flake-utils": {
|
||||||
|
"inputs": {
|
||||||
|
"systems": "systems"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1731533236,
|
||||||
|
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"home-manager": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": "nixpkgs"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1779507042,
|
||||||
|
"narHash": "sha256-7wOwi8B6D0BYsieZCnHZZj2sNUzgJhLoIVSfkwB7lxQ=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"rev": "509ed3c603349a9d43de9e2ae6613baea6bd5b34",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "home-manager",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1778443072,
|
||||||
|
"narHash": "sha256-zi7/fsqM/kFdNuED//4WOCUtezGtKKqRNORjMvfwjnA=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "da5ad661ba4e5ef59ba743f0d112cbc30e474f32",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"ref": "nixos-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nixpkgs_2": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1779357205,
|
||||||
|
"narHash": "sha256-cCO8aTqss5x9Ky8GWkpY0Hy5fyTZEbtifSUV8QjSzic=",
|
||||||
|
"owner": "NixOS",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"rev": "f83fc3c307e74bc5fd5adb7eb6b8b13ffd2a36e1",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "NixOS",
|
||||||
|
"ref": "nixos-unstable",
|
||||||
|
"repo": "nixpkgs",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": {
|
||||||
|
"inputs": {
|
||||||
|
"darwin": "darwin",
|
||||||
|
"flake-utils": "flake-utils",
|
||||||
|
"home-manager": "home-manager",
|
||||||
|
"nixpkgs": "nixpkgs_2"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"systems": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"root": "root",
|
||||||
|
"version": 7
|
||||||
|
}
|
||||||
@@ -14,7 +14,6 @@
|
|||||||
systems = [
|
systems = [
|
||||||
"x86_64-linux"
|
"x86_64-linux"
|
||||||
"aarch64-linux"
|
"aarch64-linux"
|
||||||
# "x86_64-darwin"
|
|
||||||
"aarch64-darwin"
|
"aarch64-darwin"
|
||||||
];
|
];
|
||||||
forAllSystems = f: nixpkgs.lib.genAttrs systems f;
|
forAllSystems = f: nixpkgs.lib.genAttrs systems f;
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
final: prev: { }
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
{ pkgs }: {
|
{ pkgs }: {
|
||||||
sable-web = pkgs.callPackage ./common/sable.nix {};
|
sable-web = pkgs.callPackage ./common/sable.nix {};
|
||||||
music-presense = pkgs.callPackage ./linux/music-presence.nix {};
|
swaytreesave = pkgs.callPackage ./linux/swaytreesave.nix {};
|
||||||
|
musicpresence = pkgs.callPackage ./linux/musicpresence.nix {};
|
||||||
vintage-story = pkgs.callPackage ./linux/vintage-story.nix {};
|
vintage-story = pkgs.callPackage ./linux/vintage-story.nix {};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,28 +0,0 @@
|
|||||||
{ pkgs }:
|
|
||||||
{
|
|
||||||
default =
|
|
||||||
let
|
|
||||||
pname = "musicpresence";
|
|
||||||
version = "2.3.5";
|
|
||||||
|
|
||||||
src = pkgs.fetchurl {
|
|
||||||
url = "https://github.com/ungive/discord-music-presence/releases/download/v${version}/${pname}-${version}-linux-x86_64.AppImage";
|
|
||||||
hash = "sha256-M7oDxVevspA3SGuHktS8ChQAYopgIqypiVlzyE4uyqI=";
|
|
||||||
};
|
|
||||||
|
|
||||||
appimageContents = pkgs.appimageTools.extract { inherit pname version src; };
|
|
||||||
in
|
|
||||||
pkgs.appimageTools.wrapType2 {
|
|
||||||
inherit pname version src;
|
|
||||||
|
|
||||||
nativeBuildInputs = with pkgs; [ makeWrapper ];
|
|
||||||
extraInstallCommands = ''
|
|
||||||
wrapProgram $out/bin/${pname} \
|
|
||||||
--set QT_QPA_PLATFORM xcb \
|
|
||||||
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
|
|
||||||
install -Dm444 ${appimageContents}/musicpresence.desktop -t $out/share/applications
|
|
||||||
'';
|
|
||||||
|
|
||||||
passthru.updateScript = pkgs.nix-update-script { };
|
|
||||||
};
|
|
||||||
}
|
|
||||||
27
pkgs/linux/musicpresence.nix
Normal file
27
pkgs/linux/musicpresence.nix
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
let
|
||||||
|
pname = "musicpresence";
|
||||||
|
version = "2.3.5";
|
||||||
|
|
||||||
|
src = pkgs.fetchurl {
|
||||||
|
url = "https://github.com/ungive/discord-music-presence/releases/download/v${version}/${pname}-${version}-linux-x86_64.AppImage";
|
||||||
|
hash = "sha256-M7oDxVevspA3SGuHktS8ChQAYopgIqypiVlzyE4uyqI=";
|
||||||
|
};
|
||||||
|
|
||||||
|
appimageContents = pkgs.appimageTools.extract {
|
||||||
|
inherit pname version src;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
pkgs.appimageTools.wrapType2 {
|
||||||
|
inherit pname version src;
|
||||||
|
|
||||||
|
nativeBuildInputs = with pkgs; [ makeWrapper ];
|
||||||
|
extraInstallCommands = ''
|
||||||
|
wrapProgram $out/bin/${pname} \
|
||||||
|
--set QT_QPA_PLATFORM xcb \
|
||||||
|
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=auto --enable-features=WaylandWindowDecorations}}"
|
||||||
|
install -Dm444 ${appimageContents}/musicpresence.desktop -t $out/share/applications
|
||||||
|
'';
|
||||||
|
|
||||||
|
passthru.updateScript = pkgs.nix-update-script { };
|
||||||
|
}
|
||||||
24
pkgs/linux/swaytreesave.nix
Normal file
24
pkgs/linux/swaytreesave.nix
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
{ pkgs }:
|
||||||
|
let
|
||||||
|
pname = "swaytreesave";
|
||||||
|
version = "0.4.0";
|
||||||
|
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "fabienjuif";
|
||||||
|
repo = "swaytreesave";
|
||||||
|
rev = "v${version}";
|
||||||
|
sha256 = "sha256-aAJBbauOiFERABF13hMhxyvRBzcx5c1F+vbm/U+JS8o=";
|
||||||
|
};
|
||||||
|
in pkgs.rustPlatform.buildRustPackage {
|
||||||
|
inherit pname version src;
|
||||||
|
cargoLock = { lockFile = "${src}/Cargo.lock"; };
|
||||||
|
|
||||||
|
meta = {
|
||||||
|
description = "CLI to save and load your compositors tree/layout";
|
||||||
|
mainProgram = "swaytreesave";
|
||||||
|
homepage = "https://github.com/fabienjuif/swaytreesave";
|
||||||
|
maintainers = [ "wymillerlinux" ];
|
||||||
|
platforms = [ "x86_64-linux" ];
|
||||||
|
changelog = "https://github.com/fabienjuif/swaytreesave/releases/tag/v${version}";
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -2,8 +2,7 @@
|
|||||||
let
|
let
|
||||||
x11Support = true;
|
x11Support = true;
|
||||||
waylandSupport = true;
|
waylandSupport = true;
|
||||||
in {
|
in pkgs.stdenv.mkDerivation (finalAttrs:
|
||||||
default = pkgs.stdenv.mkDerivation (finalAttrs:
|
|
||||||
let
|
let
|
||||||
inherit (pkgs) lib;
|
inherit (pkgs) lib;
|
||||||
in {
|
in {
|
||||||
@@ -97,5 +96,5 @@ in {
|
|||||||
ln -sf "$filename" "''${file%/*}"/"''${filename,,}"
|
ln -sf "$filename" "''${file%/*}"/"''${filename,,}"
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
});
|
}
|
||||||
}
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user