|
1 | | -# Aurora Shell π |
| 1 | +# Aurora Shell |
2 | 2 |
|
3 | | -An alternative GNOME Shell with various modifications and features missing in vanilla GNOME to make the user's life easier. |
| 3 | +A modular GNOME Shell extension that adds quality-of-life features missing in vanilla GNOME. |
4 | 4 |
|
5 | | -Aurora Shell is a modular GNOME Shell extension designed to scale from simple customizations to a complete custom shell experience. It provides quality-of-life improvements, visual enhancements, and workflow optimizations that vanilla GNOME lacks. |
| 5 | +## Modules |
6 | 6 |
|
7 | | -## β¨ Features |
| 7 | +| Module | Description | |
| 8 | +|--------|-------------| |
| 9 | +| **Theme Changer** | Syncs panel style with system color scheme (light/dark) | |
| 10 | +| **Dock** | Taskbar with auto-hide, intellihide, per-monitor and per-workspace activity filtering | |
| 11 | +| **No Overview** | Disables the overview on startup | |
| 12 | +| **Pip On Top** | Keeps Picture-in-Picture windows always on top (Wayland fix) | |
8 | 13 |
|
9 | | -### Current |
10 | | -- π¨ **Automatic Theme Sync** - Panel automatically matches your system theme |
11 | | -- π **Dark Mode Integration** - Seamlessly toggles between light and dark styles |
12 | | -- π **Smart Color Management** - Forces consistent color scheme preferences |
13 | | -- β‘ **Zero Configuration** - Works automatically after installation |
14 | | -- π― **Lightweight & Efficient** - Minimal performance impact |
15 | | -- ποΈ **Modular Architecture** - Easy to extend with new features |
| 14 | +All modules can be toggled independently via the extension preferences. |
16 | 15 |
|
17 | | -### Planned |
18 | | -- πͺ **Enhanced Window Management** - Tiling and snap assist |
19 | | -- οΏ½οΈ **Custom Animations** - Smooth transitions and effects |
20 | | -- π **Workspace Enhancements** - Better workspace management |
21 | | -- ποΈ **Hot Corners Customization** - Configurable corner actions |
22 | | -- π **Notification Improvements** - Enhanced notification center |
23 | | -- π¨ **Full Theming Support** - Complete visual customization |
| 16 | +## Requirements |
24 | 17 |
|
25 | | -## π Requirements |
| 18 | +- GNOME Shell 45+ |
| 19 | +- [Node.js](https://nodejs.org/) 20+ |
| 20 | +- [Yarn](https://yarnpkg.com/) 4+ |
| 21 | +- [just](https://github.com/casey/just) (command runner) |
26 | 22 |
|
27 | | -- GNOME Shell 49+ |
28 | | -- Node.js and npm (for development/compilation) |
29 | | -- TypeScript 5.9+ |
30 | | -- Sass (for stylesheet compilation) |
31 | | - |
32 | | -## π Quick Installation |
33 | | - |
34 | | -### Method 1: Using Make (Easiest) |
| 23 | +## Installation |
35 | 24 |
|
36 | 25 | ```bash |
37 | | -# Clone the repository |
38 | 26 | git clone https://github.com/luminusOS/aurora-shell.git |
39 | 27 | cd aurora-shell |
40 | | - |
41 | | -# Install and activate (all in one command) |
42 | | -make all |
| 28 | +just install |
43 | 29 | ``` |
44 | 30 |
|
45 | | -### Method 2: Installation Script |
46 | | - |
47 | | -```bash |
48 | | -# Clone the repository |
49 | | -git clone https://github.com/luminusOS/aurora-shell.git |
50 | | -cd aurora-shell |
| 31 | +## Commands |
51 | 32 |
|
52 | | -# Run the installation script |
53 | | -npm install |
54 | | -npm run build |
55 | | -make install |
56 | | -make enable |
| 33 | +``` |
| 34 | +just # list all commands |
| 35 | +just build # build everything (deps + CSS + TS + zip) |
| 36 | +just install # build + install to GNOME Shell |
| 37 | +just quick # rebuild + copy files (skip full install) |
| 38 | +just uninstall # disable + remove extension |
| 39 | +just logs # show recent extension logs |
| 40 | +just clean # remove build artifacts |
| 41 | +just distclean # remove artifacts + node_modules |
| 42 | +just validate # type-check without emitting |
| 43 | +just lint # run eslint |
| 44 | +just watch # watch SCSS for changes |
57 | 45 | ``` |
58 | 46 |
|
59 | | -### Testing |
60 | | - |
61 | | -To test the extension, use the follow command: |
| 47 | +## Testing |
62 | 48 |
|
63 | | -- Gnome 49 and later |
64 | 49 | ```bash |
| 50 | +# GNOME 49+ |
65 | 51 | dbus-run-session -- gnome-shell --devkit |
66 | | -``` |
67 | 52 |
|
68 | | -- Gnome 48 and earlier |
69 | | -```bash |
| 53 | +# GNOME 48 and earlier |
70 | 54 | dbus-run-session -- gnome-shell --nested --wayland |
71 | 55 | ``` |
72 | 56 |
|
73 | | -## ποΈ Uninstallation |
74 | | - |
75 | | -```bash |
76 | | -make uninstall |
77 | | -``` |
78 | | - |
79 | | -Or manually: |
80 | | - |
81 | | -```bash |
82 | | -gnome-extensions disable aurora-shell@luminusos.com |
83 | | -rm -rf ~/.local/share/gnome-shell/extensions/aurora-shell@luminusos.com |
84 | | -``` |
85 | | - |
86 | | -## ποΈ Architecture |
87 | | - |
88 | | -Aurora Shell is built with scalability in mind, using a modular architecture that makes it easy to add new features without affecting existing code. |
| 57 | +## Adding a Module |
89 | 58 |
|
90 | | -### Module System |
91 | | - |
92 | | -All modules implement the `AuroraModule` interface and extend `BaseAuroraModule`: |
| 59 | +1. Create `src/modules/myModule.ts`: |
93 | 60 |
|
94 | 61 | ```typescript |
95 | | -export interface AuroraModule { |
96 | | - enable(): void; |
97 | | - disable(): void; |
98 | | -} |
| 62 | +import { Module } from './module.ts'; |
99 | 63 |
|
100 | | -export abstract class BaseAuroraModule implements AuroraModule { |
101 | | - protected _console: ConsoleLike; |
102 | | - |
103 | | - constructor(console: ConsoleLike) { |
104 | | - this._console = console; |
| 64 | +export class MyModule extends Module { |
| 65 | + override enable(): void { |
| 66 | + // setup |
105 | 67 | } |
106 | | - |
107 | | - protected log(message: string, ...args: any[]): void; |
108 | | - protected error(message: string, ...args: any[]): void; |
109 | | - protected warn(message: string, ...args: any[]): void; |
110 | | - |
111 | | - abstract enable(): void; |
112 | | - abstract disable(): void; |
113 | | -} |
114 | | -``` |
115 | | - |
116 | | -**Benefits:** |
117 | | -- β
Clean separation of concerns |
118 | | -- β
Easy to add new features |
119 | | -- β
Each module is independently testable |
120 | | -- β
Consistent logging interface |
121 | | -- β
Type-safe with TypeScript |
122 | | - |
123 | | -### Style System |
124 | | - |
125 | | -Styles are organized using SCSS with a modular structure: |
126 | | - |
127 | | -``` |
128 | | -src/styles/ |
129 | | -βββ stylesheet.scss # Main file (imports all modules) |
130 | | -βββ _variables.scss # Global variables |
131 | | -β βββ Colors ($aurora-dash-bg, $aurora-hover-bg, etc) |
132 | | -β βββ Transitions ($aurora-transition-duration, etc) |
133 | | -β βββ Spacing ($aurora-button-padding, etc) |
134 | | -β βββ Border radius ($aurora-border-radius, etc) |
135 | | -βββ _panel.scss # Panel-specific styles |
136 | | -``` |
137 | 68 |
|
138 | | -**Features:** |
139 | | -- β
Variables for easy customization |
140 | | -- β
Modular organization (one file per component) |
141 | | -- β
Modern SCSS with `@use` syntax |
142 | | -- β
Automatic compilation with Sass |
143 | | -- β
Single compiled output: `dist/stylesheet.css` |
144 | | - |
145 | | -**Adding new styles:** |
146 | | -1. Create `_component.scss` with component styles |
147 | | -2. Add `@use 'component';` to `stylesheet.scss` |
148 | | -3. Run `npm run build:css` to compile |
149 | | - |
150 | | -### Current Modules |
151 | | - |
152 | | -#### ThemeChanger |
153 | | -- **File**: `src/modules/themeChanger.ts` |
154 | | -- **Purpose**: Monitors and controls GNOME's Dark Style |
155 | | -- **Features**: |
156 | | - - Detects `color-scheme` changes |
157 | | - - Forces `prefer-light` when Dark Style is disabled |
158 | | - - Adds CSS classes to panel (`aurora-dark-mode`, `aurora-light-mode`) |
159 | | - - Public API: `setDarkMode()`, `setLightMode()`, `toggleMode()` |
160 | | - |
161 | | -### Adding New Modules |
162 | | - |
163 | | -1. **Create module file** in `src/modules/` |
164 | | -2. **Extend BaseAuroraModule** |
165 | | -3. **Implement enable() and disable()** |
166 | | -4. **Register in extension.ts** |
167 | | - |
168 | | -Example: |
169 | | - |
170 | | -```typescript |
171 | | -// src/modules/MyFeature.ts |
172 | | -import { BaseAuroraModule } from './BaseModule.js'; |
173 | | - |
174 | | -export class MyFeature extends BaseAuroraModule { |
175 | | - enable(): void { |
176 | | - this.log('MyFeature: Enabling'); |
177 | | - // Your initialization code |
178 | | - } |
179 | | - |
180 | | - disable(): void { |
181 | | - this.log('MyFeature: Disabling'); |
182 | | - // Cleanup code |
| 69 | + override disable(): void { |
| 70 | + // cleanup |
183 | 71 | } |
184 | 72 | } |
185 | | - |
186 | | -// src/extension.ts |
187 | | -import { MyFeature } from "./modules/MyFeature.js"; |
188 | | - |
189 | | -private _initializeModules(): void { |
190 | | - this._modules.set('myFeature', new MyFeature(this._console!)); |
191 | | -} |
192 | | -``` |
193 | | - |
194 | | -### Build System |
195 | | - |
196 | | -Aurora Shell uses **esbuild** for fast bundling: |
197 | | - |
198 | | -- **Target**: Firefox 102 (GJS 1.73.2+) |
199 | | -- **Format**: ESM (ES Modules) |
200 | | -- **Bundle**: Single file output |
201 | | -- **External**: `gi://*`, `resource://*`, `system`, `gettext`, `cairo` |
202 | | - |
203 | | -Build commands: |
204 | | -```bash |
205 | | -npm run build # Full build (TS + CSS) |
206 | | -npm run build:ts # TypeScript only |
207 | | -npm run build:css # SCSS only |
208 | | -npm run validate # Type check without compiling |
209 | 73 | ``` |
210 | 74 |
|
211 | | -## π Troubleshooting |
| 75 | +2. Register in `src/registry.ts`: |
212 | 76 |
|
213 | | -### Extension not working |
214 | | - |
215 | | -1. Check if extension is enabled: |
216 | | -```bash |
217 | | -gnome-extensions list |
218 | | -``` |
219 | | - |
220 | | -2. Check logs for errors: |
221 | | -```bash |
222 | | -journalctl -f -o cat /usr/bin/gnome-shell | grep "Aurora Shell" |
223 | | -``` |
224 | | - |
225 | | -### Colors not syncing |
226 | | - |
227 | | -1. Make sure you're in dark mode |
228 | | -2. Restart GNOME Shell (logout/login on Wayland) |
229 | | -3. Try disabling and re-enabling: |
230 | | -```bash |
231 | | -make reload |
232 | | -``` |
233 | | - |
234 | | -### Type checking |
| 77 | +```typescript |
| 78 | +import { MyModule } from './modules/myModule.ts'; |
235 | 79 |
|
236 | | -Validate TypeScript without compiling: |
237 | | -```bash |
238 | | -npm run validate |
| 80 | +// Add to MODULE_REGISTRY: |
| 81 | +{ key: 'myModule', settingsKey: 'module-my-module', create: () => new MyModule(), title: 'My Module', subtitle: 'Description' }, |
239 | 82 | ``` |
240 | 83 |
|
241 | | -## π» Development |
| 84 | +3. Add key to `schemas/org.gnome.shell.extensions.aurora-shell.gschema.xml`: |
242 | 85 |
|
243 | | -### Building |
244 | | - |
245 | | -```bash |
246 | | -npm run build # Build everything |
247 | | -npm run build:ts # TypeScript only |
248 | | -npm run build:css # SCSS only |
| 86 | +```xml |
| 87 | +<key name="module-my-module" type="b"> |
| 88 | + <default>true</default> |
| 89 | + <summary>Enable My Module</summary> |
| 90 | + <description>What this module does</description> |
| 91 | +</key> |
249 | 92 | ``` |
250 | 93 |
|
251 | | -### Code Style |
| 94 | +The module automatically appears in extension preferences and responds to runtime toggle. |
252 | 95 |
|
253 | | -- **Files**: camelCase (`themeChanger.ts`) |
254 | | -- **Classes**: PascalCase (`ThemeChanger`) |
255 | | -- **Private methods**: Prefix `_` (`_applyTheme()`) |
256 | | -- **Constants**: UPPER_CASE (`DASH_COLOR`) |
| 96 | +## Build System |
257 | 97 |
|
258 | | -### Logging |
| 98 | +- **esbuild** bundles TypeScript (target: Firefox 102 / GJS 1.73.2+, format: ESM) |
| 99 | +- **Sass** compiles SCSS stylesheets (light + dark variants) |
| 100 | +- **AdmZip** packages the extension as a `.zip` for distribution |
259 | 101 |
|
260 | | -Always prefix logs with module name: |
| 102 | +## Code Style |
261 | 103 |
|
262 | | -```typescript |
263 | | -this.log('MyModule: Something happened'); |
264 | | -this.error('MyModule: Error occurred:', error); |
265 | | -``` |
| 104 | +- Files: `camelCase.ts` |
| 105 | +- Classes: `PascalCase` |
| 106 | +- Private members: `_prefixed` |
| 107 | +- Constants: `UPPER_CASE` |
266 | 108 |
|
267 | | -## π License |
| 109 | +## License |
268 | 110 |
|
269 | 111 | LGPL-3.0-or-later |
270 | | - |
271 | | -## π€ Contributing |
272 | | - |
273 | | -Contributions are very welcome! Feel free to: |
274 | | - |
275 | | -- π Report bugs |
276 | | -- π‘ Suggest new features |
277 | | -- π§ Submit pull requests |
278 | | -- π Improve documentation |
279 | | - |
280 | | -### How to Contribute |
281 | | - |
282 | | -1. Fork the project |
283 | | -2. Create a feature branch (`git checkout -b feature/my-feature`) |
284 | | -3. Commit your changes (`git commit -m 'feat: Add MyFeature'`) |
285 | | -4. Push to the branch (`git push origin feature/my-feature`) |
286 | | -5. Open a Pull Request |
287 | | - |
288 | | -### Development Guidelines |
289 | | - |
290 | | -- One module = one feature |
291 | | -- Always implement `enable()` and `disable()` |
292 | | -- Clean up all resources in `disable()` |
293 | | -- Add informative logs |
294 | | -- Document parameters and behavior |
295 | | -- Follow TypeScript best practices |
296 | | - |
297 | | -## π Acknowledgments |
298 | | - |
299 | | -Developed with β€οΈ for the GNOME community. |
300 | | - |
301 | | -Special thanks to: |
302 | | -- GNOME Shell team |
303 | | -- GJS contributors |
304 | | -- @girs package maintainers |
305 | | - |
306 | | -## π Support |
307 | | - |
308 | | -- **Issues**: [GitHub Issues](https://github.com/luminusOS/aurora-shell/issues) |
309 | | -- **Discussions**: [GitHub Discussions](https://github.com/luminusOS/aurora-shell/discussions) |
0 commit comments