Remove AGS and get waybar again also fuck AGS with its typescript bullshit
This commit is contained in:
@@ -62,6 +62,7 @@
|
||||
|
||||
services.dbus.enable = true;
|
||||
services.gvfs.enable = true;
|
||||
programs.nix-ld.enable = true;
|
||||
|
||||
xdg.portal.enable = true;
|
||||
|
||||
|
||||
2
modules/ags/config/.gitignore
vendored
2
modules/ags/config/.gitignore
vendored
@@ -1,2 +0,0 @@
|
||||
node_modules/
|
||||
@girs/
|
||||
@@ -1,10 +0,0 @@
|
||||
import app from "ags/gtk4/app"
|
||||
import style from "./style.scss"
|
||||
import Bar from "./widget/Bar"
|
||||
|
||||
app.start({
|
||||
css: style,
|
||||
main() {
|
||||
app.get_monitors().map(Bar)
|
||||
},
|
||||
})
|
||||
21
modules/ags/config/env.d.ts
vendored
21
modules/ags/config/env.d.ts
vendored
@@ -1,21 +0,0 @@
|
||||
declare const SRC: string
|
||||
|
||||
declare module "inline:*" {
|
||||
const content: string
|
||||
export default content
|
||||
}
|
||||
|
||||
declare module "*.scss" {
|
||||
const content: string
|
||||
export default content
|
||||
}
|
||||
|
||||
declare module "*.blp" {
|
||||
const content: string
|
||||
export default content
|
||||
}
|
||||
|
||||
declare module "*.css" {
|
||||
const content: string
|
||||
export default content
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"ags": "*",
|
||||
"gnim": "*"
|
||||
},
|
||||
"prettier": {
|
||||
"semi": false,
|
||||
"tabWidth": 2
|
||||
}
|
||||
}
|
||||
@@ -1,20 +0,0 @@
|
||||
// https://gitlab.gnome.org/GNOME/gtk/-/blob/gtk-3-24/gtk/theme/Adwaita/_colors-public.scss
|
||||
$fg-color: #{"@theme_fg_color"};
|
||||
$bg-color: #{"@theme_bg_color"};
|
||||
|
||||
window.Bar {
|
||||
background: transparent;
|
||||
color: $fg-color;
|
||||
font-weight: bold;
|
||||
|
||||
> centerbox {
|
||||
background: $bg-color;
|
||||
border-radius: 10px;
|
||||
margin: 8px;
|
||||
}
|
||||
|
||||
button {
|
||||
border-radius: 8px;
|
||||
margin: 2px;
|
||||
}
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
{
|
||||
"$schema": "https://json.schemastore.org/tsconfig",
|
||||
"compilerOptions": {
|
||||
"strict": true,
|
||||
"module": "ES2022",
|
||||
"target": "ES2020",
|
||||
"lib": ["ES2023"],
|
||||
"moduleResolution": "Bundler",
|
||||
// "checkJs": true,
|
||||
// "allowJs": true,
|
||||
"jsx": "react-jsx",
|
||||
"jsxImportSource": "ags/gtk4"
|
||||
}
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
import app from "ags/gtk4/app"
|
||||
import { Astal, Gtk, Gdk } from "ags/gtk4"
|
||||
import { execAsync } from "ags/process"
|
||||
import { createPoll } from "ags/time"
|
||||
import Tray from "gi://AstalTray"
|
||||
|
||||
export default function Bar(gdkmonitor: Gdk.Monitor) {
|
||||
const time = createPoll("", 1000, "date")
|
||||
const { TOP, LEFT, RIGHT } = Astal.WindowAnchor
|
||||
|
||||
const tray = Tray.get_default()
|
||||
|
||||
for (const item of tray.get_items()) {
|
||||
print(item.title)
|
||||
}
|
||||
|
||||
return (
|
||||
<window
|
||||
visible
|
||||
name="bar"
|
||||
class="Bar"
|
||||
gdkmonitor={gdkmonitor}
|
||||
exclusivity={Astal.Exclusivity.EXCLUSIVE}
|
||||
anchor={TOP | LEFT | RIGHT}
|
||||
application={app}
|
||||
>
|
||||
<centerbox cssName="centerbox">
|
||||
<button
|
||||
$type="start"
|
||||
onClicked={() => execAsync("echo hello").then(console.log)}
|
||||
hexpand
|
||||
halign={Gtk.Align.CENTER}
|
||||
>
|
||||
<label label="Welcome to AGS!" />
|
||||
</button>
|
||||
<box $type="center" />
|
||||
<menubutton $type="end" hexpand halign={Gtk.Align.CENTER}>
|
||||
<label label={time} />
|
||||
<popover>
|
||||
<Gtk.Calendar />
|
||||
</popover>
|
||||
</menubutton>
|
||||
</centerbox>
|
||||
</window>
|
||||
)
|
||||
}
|
||||
70
modules/ags/flake.lock
generated
70
modules/ags/flake.lock
generated
@@ -1,70 +0,0 @@
|
||||
{
|
||||
"nodes": {
|
||||
"ags": {
|
||||
"inputs": {
|
||||
"astal": "astal",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764289441,
|
||||
"narHash": "sha256-ak+lgFiYE5PHByN1/BRkO5JP498hno6Ix24C1Qf/vec=",
|
||||
"owner": "aylur",
|
||||
"repo": "ags",
|
||||
"rev": "e169694390548dfd38ff40f1ef2163d6c3ffe3ea",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "aylur",
|
||||
"repo": "ags",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"astal": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"ags",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764173295,
|
||||
"narHash": "sha256-Jh4VtPcK2Ov+RTcV9FtyQRsxiJmXFQGfqX6jjM7/mgc=",
|
||||
"owner": "aylur",
|
||||
"repo": "astal",
|
||||
"rev": "7d1fac8a4b2a14954843a978d2ddde86168c75ef",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "aylur",
|
||||
"repo": "astal",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1771008912,
|
||||
"narHash": "sha256-gf2AmWVTs8lEq7z/3ZAsgnZDhWIckkb+ZnAo5RzSxJg=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "a82ccc39b39b621151d6732718e3e250109076fa",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"ags": "ags",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
||||
@@ -1,72 +0,0 @@
|
||||
{
|
||||
description = "My Awesome Desktop Shell";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
|
||||
|
||||
ags = {
|
||||
url = "github:aylur/ags";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
ags,
|
||||
}: let
|
||||
system = "x86_64-linux";
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
pname = "my-shell";
|
||||
entry = "app.ts";
|
||||
|
||||
astalPackages = with ags.packages.${system}; [
|
||||
io
|
||||
astal4 # or astal3 for gtk3
|
||||
# notifd tray wireplumber
|
||||
];
|
||||
|
||||
extraPackages =
|
||||
astalPackages
|
||||
++ [
|
||||
pkgs.libadwaita
|
||||
pkgs.libsoup_3
|
||||
];
|
||||
in {
|
||||
packages.${system} = {
|
||||
default = pkgs.stdenv.mkDerivation {
|
||||
name = pname;
|
||||
src = ./.;
|
||||
|
||||
nativeBuildInputs = with pkgs; [
|
||||
wrapGAppsHook3
|
||||
gobject-introspection
|
||||
ags.packages.${system}.default
|
||||
];
|
||||
|
||||
buildInputs = extraPackages ++ [pkgs.gjs];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/bin
|
||||
mkdir -p $out/share
|
||||
cp -r * $out/share
|
||||
ags bundle ${entry} $out/bin/${pname} -d "SRC='$out/share'"
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
devShells.${system} = {
|
||||
default = pkgs.mkShell {
|
||||
buildInputs = [
|
||||
(ags.packages.${system}.default.override {
|
||||
inherit extraPackages;
|
||||
})
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -69,7 +69,7 @@
|
||||
vulkan-tools
|
||||
unzip
|
||||
adwsteamgtk
|
||||
ags
|
||||
waybar
|
||||
obs-studio
|
||||
gtk4
|
||||
libadwaita
|
||||
@@ -81,8 +81,5 @@
|
||||
pango
|
||||
gdk-pixbuf
|
||||
cairo
|
||||
|
||||
astal.astal4
|
||||
astal.tray
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user