Skip to content

Commit 1036215

Browse files
Merge pull request #1 from ExpidusOS/feat/miso
feat: use shoyu/miso
2 parents 0632044 + aa55de0 commit 1036215

28 files changed

+316
-369
lines changed

.github/workflows/deploy.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Publish to GitHub Pages
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v2
12+
- uses: subosito/flutter-action@v1
13+
with:
14+
channel: stable
15+
- run: flutter pub get
16+
- uses: bluefireteam/flutter-gh-pages@v7
17+
with:
18+
baseHref: /

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,11 @@
1-
# genesis
1+
# Genesis Shell
2+
23
Next generation desktop & mobile shell
4+
5+
## Why Flutter?
6+
7+
Flutter supports mobile and desktop devices. Since the goal is to provide
8+
a convergence experience, it would make sense to use a framework designed
9+
for both mobile and desktop devices. The adaptive and responsive nature
10+
of Flutter along side with it's easy to use developer tools makes it
11+
a great contender.
346 KB
Loading

assets/wallpaper/desktop/default.jpg

10.1 MB
Loading

assets/wallpaper/desktop/lake.jpg

400 KB
Loading
236 KB
Loading
5 MB
Loading

assets/wallpaper/mobile/default.jpg

1000 KB
Loading
6.43 MB
Loading
1.97 MB
Loading

flake.lock

Lines changed: 94 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 110 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -2,65 +2,134 @@
22
description = "Next generation mobile/desktop shell";
33

44
inputs = {
5-
nixpkgs.url = "github:ExpidusOS/nixpkgs/feat/flutter-3-26-pre";
5+
nixpkgs.url = "github:NixOS/nixpkgs/release-24.11";
66
systems.url = "github:nix-systems/default-linux";
77
flake-utils.url = "github:numtide/flake-utils";
8+
nixos-apple-silicon = {
9+
url = "github:tpwrules/nixos-apple-silicon/release-2024-12-25";
10+
inputs.nixpkgs.follows = "nixpkgs";
11+
};
12+
shoyu = {
13+
url = "github:MidstallSoftware/shoyu";
14+
inputs = {
15+
nixpkgs.follows = "nixpkgs";
16+
systems.follows = "systems";
17+
flake-utils.follows = "flake-utils";
18+
nixos-apple-silicon.follows = "nixos-apple-silicon";
19+
};
20+
};
821
};
922

10-
outputs = { self, nixpkgs, systems, flake-utils }:
23+
outputs =
24+
{
25+
self,
26+
nixpkgs,
27+
systems,
28+
flake-utils,
29+
nixos-apple-silicon,
30+
shoyu,
31+
...
32+
}:
1133
let
1234
inherit (nixpkgs) lib;
1335
in
14-
flake-utils.lib.eachSystem (import systems) (system:
36+
flake-utils.lib.eachSystem (import systems) (
37+
system:
1538
let
16-
pkgs = nixpkgs.legacyPackages.${system};
39+
pkgs = nixpkgs.legacyPackages.${system}.appendOverlays [
40+
(
41+
pkgs: prev: with pkgs; {
42+
pkgsAsahi = (
43+
if stdenv.hostPlatform.isAarch64 then
44+
pkgs.appendOverlays [
45+
nixos-apple-silicon.overlays.default
46+
(pkgsAsahi: prev: {
47+
mesa = pkgsAsahi.mesa-asahi-edge.overrideAttrs (
48+
f: p: {
49+
meta.platforms = prev.mesa.meta.platforms;
50+
}
51+
);
52+
})
53+
]
54+
else
55+
null
56+
);
57+
58+
genesis-shell = pkgs.flutter327.buildFlutterApplication {
59+
pname = "genesis-shell";
60+
version = "${shortVersion}+git-${shortRev}";
61+
62+
src = lib.cleanSource self;
63+
64+
flutterBuildFlags = [
65+
"--dart-define=COMMIT_HASH=${shortRev}"
66+
];
67+
68+
buildInputs = with pkgs; [
69+
pkgs.shoyu
70+
];
71+
72+
pubspecLock = lib.importJSON ./pubspec.lock.json;
73+
74+
gitHashes = {
75+
expidus = "sha256-EaOzIJvuZ5Bs75zslMCTb9ChkOX7lNUEUvsbDItyqG0=";
76+
miso = "sha256-EznEUokD0nSON/4XRHe/HT+ybPAdNtoUwXCPEla6i1Y=";
77+
};
78+
79+
meta = {
80+
description = "Next generation mobile/desktop shell.";
81+
homepage = "https://expidusos.com";
82+
license = lib.licenses.gpl3;
83+
maintainers = with lib.maintainers; [ RossComputerGuy ];
84+
platforms = [
85+
"x86_64-linux"
86+
"aarch64-linux"
87+
];
88+
};
89+
};
90+
}
91+
)
92+
shoyu.overlays.default
93+
];
94+
1795
deps = builtins.fromJSON (lib.readFile ./deps.json);
1896
shortRev = self.shortRev or (lib.substring 7 7 lib.fakeHash);
1997
shortRevCodes = lib.map lib.strings.charToInt (lib.stringToCharacters shortRev);
2098
buildCode = lib.foldr (a: b: "${toString a}${toString b}") "" shortRevCodes;
2199

22100
shortVersion = "1.0.0";
23101
version = "${shortVersion}+${buildCode}";
24-
in {
25-
packages.default = pkgs.flutter326.buildFlutterApplication {
26-
pname = "genesis-shell";
27-
version = "${shortVersion}+git-${shortRev}";
28-
29-
src = lib.cleanSource self;
30-
31-
flutterBuildFlags = [
32-
"--dart-define=COMMIT_HASH=${shortRev}"
33-
];
34-
35-
buildInputs = with pkgs; [
36-
gtk-layer-shell
37-
];
38102

39-
pubspecLock = lib.importJSON ./pubspec.lock.json;
40-
41-
gitHashes = {
42-
expidus = "sha256-MJWcL4MDbM4Oz1eaWZZrQQoVNeJMyl0/oWQlmdQcMKg=";
103+
mkDevShell =
104+
pkgs:
105+
pkgs.mkShell {
106+
packages = with pkgs; [
107+
flutter327
108+
pkg-config
109+
gtk3
110+
yq
111+
pkgs.shoyu
112+
];
43113
};
44-
45-
meta = {
46-
description = "Next generation mobile/desktop shell.";
47-
homepage = "https://expidusos.com";
48-
license = lib.licenses.gpl3;
49-
maintainers = with lib.maintainers; [ RossComputerGuy ];
50-
platforms = [ "x86_64-linux" "aarch64-linux" ];
114+
in
115+
{
116+
packages =
117+
{
118+
default = pkgs.genesis-shell;
119+
}
120+
// lib.optionalAttrs (pkgs.pkgsAsahi != null) {
121+
asahi = pkgs.pkgsAsahi.genesis-shell;
51122
};
52-
};
53123

54-
devShells.default = pkgs.mkShell {
55-
inherit (self.packages.${system}.default) pname version name;
124+
devShells =
125+
{
126+
default = mkDevShell pkgs;
127+
}
128+
// lib.optionalAttrs (pkgs.pkgsAsahi != null) {
129+
asahi = mkDevShell pkgs.pkgsAsahi;
130+
};
56131

57-
packages = with pkgs; [
58-
flutter326
59-
pkg-config
60-
gtk3
61-
gtk-layer-shell
62-
yq
63-
];
64-
};
65-
});
132+
legacyPackages = pkgs;
133+
}
134+
);
66135
}

lib/main.dart

Lines changed: 1 addition & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,32 +2,13 @@ import 'dart:io';
22

33
import 'package:expidus/expidus.dart';
44

5-
import 'views/action_dialog.dart';
6-
import 'views/backdrop.dart';
75
import 'views/desktop.dart';
8-
import 'views/panel.dart';
9-
import 'views/user_drawer.dart';
106

117
void main(List<String> args) {
12-
final mode = args.length > 0 ? args[0] : 'desktop';
13-
final monitor = args.length > 1 ? args[1] : null;
14-
158
runApp(ExpidusAppConfig(
169
ExpidusApp(
1710
title: 'Genesis Shell',
18-
home: switch (mode) {
19-
'action-dialog' => ActionDialogView(monitor: monitor),
20-
'backdrop' => BackdropView(monitor: monitor),
21-
'desktop' => DesktopView(monitor: monitor),
22-
'panel' => PanelView(monitor: monitor),
23-
'user-drawer' => UserDrawerView(monitor: monitor),
24-
(_) => throw Exception('Invalid mode $mode'),
25-
},
26-
),
27-
windowSize: const Size(0, 50),
28-
windowLayer: ExpidusWindowLayerConfig(
29-
fixedSize: true,
30-
monitor: monitor,
11+
home: const DesktopView(),
3112
),
3213
));
3314
}

0 commit comments

Comments
 (0)