diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..386ac71 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,35 @@ +--- +name: Bug report +about: Create a report to help us improve +title: 'bug: description of the bug you encountered' +labels: '' +assignees: '' + +--- + +**I confirm this bug has not already been reported** +- [ ] I have searched the issues and this bug has not been reported previously + +**Describe the bug** +A clear and concise description of what the bug is. + +**To Reproduce** +Steps to reproduce the behavior: +1. Go to '...' +2. Click on '....' +3. Scroll down to '....' +4. See error + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Desktop (please complete the following information):** + - Quickgui Versdion: [e.g 1.2.9] + - OS: [e.g. Ubuntu] + - Version [e.g. 24.04] + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Additional context** +Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..48ded58 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,23 @@ +--- +name: Feature request +about: Suggest an idea for this project +title: 'feat: describe the feature you are requesting' +labels: '' +assignees: '' + +--- + +**I confirm this feature has not been previously requested** +- [ ] I have searched the issues and this feature has not previously been requested + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. diff --git a/.github/apple.png b/.github/apple.png new file mode 100644 index 0000000..186d526 Binary files /dev/null and b/.github/apple.png differ diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 19a064f..58bfe3d 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -3,5 +3,8 @@ updates: - package-ecosystem: "github-actions" directory: "/" schedule: - # Check for updates to GitHub Actions every week - interval: "weekly" \ No newline at end of file + interval: "weekly" + - package-ecosystem: "pub" + directory: "/" + schedule: + interval: "daily" diff --git a/.github/logo.png b/.github/logo.png index e800eb4..c65d3cd 100644 Binary files a/.github/logo.png and b/.github/logo.png differ diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..7f4a7c5 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,24 @@ +# Description + +Please include a summary of the changes and any relevant motivation and context. + + + +- Closes # +- Fixes # +- Resolves # + +## Type of change + + + +- [ ] Bug fix (non-breaking change which fixes an issue) +- [ ] New feature (non-breaking change which adds functionality) +- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected) +- [ ] Documentation (updates documentation) + +# Checklist: + +- [ ] I have performed a self-review of my code +- [ ] I have commented my code, particularly in hard-to-understand areas +- [ ] I have made corresponding changes to the documentation diff --git a/.github/tux.png b/.github/tux.png new file mode 100644 index 0000000..0a9d855 Binary files /dev/null and b/.github/tux.png differ diff --git a/.github/workflows/build-quickgui.yml b/.github/workflows/build-quickgui.yml index 76ee0f6..24877fe 100644 --- a/.github/workflows/build-quickgui.yml +++ b/.github/workflows/build-quickgui.yml @@ -4,9 +4,19 @@ on: pull_request: branches: - main + paths: + - pubspec.yaml + - assets/** + - lib/** + - linux/** push: branches: - main + paths: + - pubspec.yaml + - assets/** + - lib/** + - linux/** workflow_dispatch: # TODO: arm64 runner diff --git a/.github/workflows/flake-checker.yml b/.github/workflows/flake-checker.yml new file mode 100644 index 0000000..242b88c --- /dev/null +++ b/.github/workflows/flake-checker.yml @@ -0,0 +1,21 @@ +name: Flake ❄️ Checker ✅ + +on: + push: + branches: + - main + schedule: + - cron: '42 0 * * 6' + workflow_dispatch: + +jobs: + flake-checker: + name: Flake Checker + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: DeterminateSystems/nix-installer-action@v12 + - uses: DeterminateSystems/magic-nix-cache-action@v7 + - uses: DeterminateSystems/flake-checker-action@v8 diff --git a/.github/workflows/flake-updater.yml b/.github/workflows/flake-updater.yml new file mode 100644 index 0000000..9e1f790 --- /dev/null +++ b/.github/workflows/flake-updater.yml @@ -0,0 +1,20 @@ +name: Flake ❄️ Lock 🔒️ Updater ✨ + +on: + schedule: + - cron: '37 13 14,28 * *' + workflow_dispatch: + +jobs: + lock-updater: + name: Flake Lock Updater + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: DeterminateSystems/nix-installer-action@v12 + - uses: DeterminateSystems/magic-nix-cache-action@v7 + - uses: DeterminateSystems/update-flake-lock@v23 + with: + pr-title: "chore: update flake.lock" diff --git a/.github/workflows/lint-pr.yml b/.github/workflows/lint-pr.yml new file mode 100644 index 0000000..c70997b --- /dev/null +++ b/.github/workflows/lint-pr.yml @@ -0,0 +1,27 @@ +name: "Lint Pull Request 🐙" + +on: + pull_request_target: + types: + - opened + - edited + - synchronize + +permissions: + pull-requests: read + +jobs: + main: + name: Validate pull request title + runs-on: ubuntu-22.04 + steps: + - uses: amannn/action-semantic-pull-request@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + # If the PR only contains a single commit, the action will validate that + # it matches the configured pattern. + validateSingleCommit: true + # Related to `validateSingleCommit` you can opt-in to validate that the PR + # title matches a single commit to avoid confusion. + validateSingleCommitMatchesPrTitle: true diff --git a/.github/workflows/publish-quickgui.yml b/.github/workflows/publish-quickgui.yml index f3c5229..1d8cc73 100644 --- a/.github/workflows/publish-quickgui.yml +++ b/.github/workflows/publish-quickgui.yml @@ -40,9 +40,9 @@ jobs: exit 1 fi - build-linux-x64: + publish-linux-x64: needs: [version-check] - name: "Build Linux x64 🏗️" + name: "Publish Linux (x64) 🐙" runs-on: ubuntu-22.04 steps: - name: "Checkout 🥡" @@ -78,26 +78,19 @@ jobs: run: flutter_distributor package --platform=linux --targets=zip - name: Show artifacts 👀 run: tree dist/ - - publish-release: - needs: [build-linux-x64] - name: "Publish Release 📤️" - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v4 - - name: Publish release ${{ github.ref }} - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - REL_VER=$(grep "^version" pubspec.yaml | cut -d' ' -f2) - gh release create "${{ github.ref }}" --draft --generate-notes - for PKG in AppImage deb rpm zip; do - gh release upload "${{ github.ref }}" "dist/${REL_VER}/quickgui-${REL_VER}-linux.${PKG}" --clobber - done - if [ "$(gh release view "${{ github.ref }}" --json assets --template '{{len .assets}}')" -lt 0 ]; then - exit 1 - fi - gh release edit "${{ github.ref }}" --draft=false + - name: "Publish Release 📤️" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + REL_VER=$(grep "^version" pubspec.yaml | cut -d' ' -f2) + gh release create "${{ github.ref }}" --draft --generate-notes + for PKG in AppImage deb rpm zip; do + gh release upload "${{ github.ref }}" "dist/${REL_VER}/quickgui-${REL_VER}-linux.${PKG}" --clobber + done + if [ "$(gh release view "${{ github.ref }}" --json assets --template '{{len .assets}}')" -lt 0 ]; then + exit 1 + fi + gh release edit "${{ github.ref }}" --draft=false publish-flakehub: needs: [version-check] @@ -111,7 +104,7 @@ jobs: with: ref: "${{ (inputs.tag != null) && format('refs/tags/{0}', inputs.tag) || '' }}" - uses: "DeterminateSystems/nix-installer-action@v12" - - uses: "DeterminateSystems/magic-nix-cache-actionv7" + - uses: "DeterminateSystems/magic-nix-cache-action@v7" - uses: "DeterminateSystems/flakehub-push@v4" with: visibility: "public" @@ -120,6 +113,7 @@ jobs: publish-ppa-x64: needs: [version-check] + name: "Publish PPA (x64) 🟠" runs-on: ubuntu-22.04 steps: - name: "Checkout 🥡" diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..86eb31d --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,128 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +We as members, contributors, and leaders pledge to make participation in our +community a harassment-free experience for everyone, regardless of age, body +size, visible or invisible disability, ethnicity, sex characteristics, gender +identity and expression, level of experience, education, socio-economic status, +nationality, personal appearance, race, religion, or sexual identity +and orientation. + +We pledge to act and interact in ways that contribute to an open, welcoming, +diverse, inclusive, and healthy community. + +## Our Standards + +Examples of behavior that contributes to a positive environment for our +community include: + +* Demonstrating empathy and kindness toward other people +* Being respectful of differing opinions, viewpoints, and experiences +* Giving and gracefully accepting constructive feedback +* Accepting responsibility and apologizing to those affected by our mistakes, + and learning from the experience +* Focusing on what is best not just for us as individuals, but for the + overall community + +Examples of unacceptable behavior include: + +* The use of sexualized language or imagery, and sexual attention or + advances of any kind +* Trolling, insulting or derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or email + address, without their explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Enforcement Responsibilities + +Community leaders are responsible for clarifying and enforcing our standards of +acceptable behavior and will take appropriate and fair corrective action in +response to any behavior that they deem inappropriate, threatening, offensive, +or harmful. + +Community leaders have the right and responsibility to remove, edit, or reject +comments, commits, code, wiki edits, issues, and other contributions that are +not aligned to this Code of Conduct, and will communicate reasons for moderation +decisions when appropriate. + +## Scope + +This Code of Conduct applies within all community spaces, and also applies when +an individual is officially representing the community in public spaces. +Examples of representing our community include using an official e-mail address, +posting via an official social media account, or acting as an appointed +representative at an online or offline event. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported to the community leaders responsible for enforcement at +#quickemu channel on Discord. +All complaints will be reviewed and investigated promptly and fairly. + +All community leaders are obligated to respect the privacy and security of the +reporter of any incident. + +## Enforcement Guidelines + +Community leaders will follow these Community Impact Guidelines in determining +the consequences for any action they deem in violation of this Code of Conduct: + +### 1. Correction + +**Community Impact**: Use of inappropriate language or other behavior deemed +unprofessional or unwelcome in the community. + +**Consequence**: A private, written warning from community leaders, providing +clarity around the nature of the violation and an explanation of why the +behavior was inappropriate. A public apology may be requested. + +### 2. Warning + +**Community Impact**: A violation through a single incident or series +of actions. + +**Consequence**: A warning with consequences for continued behavior. No +interaction with the people involved, including unsolicited interaction with +those enforcing the Code of Conduct, for a specified period of time. This +includes avoiding interactions in community spaces as well as external channels +like social media. Violating these terms may lead to a temporary or +permanent ban. + +### 3. Temporary Ban + +**Community Impact**: A serious violation of community standards, including +sustained inappropriate behavior. + +**Consequence**: A temporary ban from any sort of interaction or public +communication with the community for a specified period of time. No public or +private interaction with the people involved, including unsolicited interaction +with those enforcing the Code of Conduct, is allowed during this period. +Violating these terms may lead to a permanent ban. + +### 4. Permanent Ban + +**Community Impact**: Demonstrating a pattern of violation of community +standards, including sustained inappropriate behavior, harassment of an +individual, or aggression toward or disparagement of classes of individuals. + +**Consequence**: A permanent ban from any sort of public interaction within +the community. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], +version 2.0, available at +https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. + +Community Impact Guidelines were inspired by [Mozilla's code of conduct +enforcement ladder](https://github.com/mozilla/diversity). + +[homepage]: https://www.contributor-covenant.org + +For answers to common questions about this code of conduct, see the FAQ at +https://www.contributor-covenant.org/faq. Translations are available at +https://www.contributor-covenant.org/translations. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..b5a2621 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,9 @@ +# Contributing + +We welcome contributions to Quickgui. + +- Help other Quickgui users by answering questions in the [Quickgui Discussions](https://github.com/quickemu-project/quickgui/discussions) 🛟 +- Improve the documentation in [this README](https://github.com/quickemu-project/quickgui/edit/master/README.md) and the [Quickgui Wiki](https://github.com/quickemu-project/quickgui/wiki) 📖 +- File bug reports and feature requests in the [Quickgui Issues](https://github.com/quickemu-project/quickgui/issues) 📁 +- Submit [Quickgui Pull requests](https://github.com/quickemu-project/quickgui/pulls) to fix bugs 🐞 or add new features ✨ + - Commit messages must [conform to the Conventional Commits specification](https://www.conventionalcommits.org/). diff --git a/README.md b/README.md index 28920da..74050c4 100644 --- a/README.md +++ b/README.md @@ -1,119 +1,156 @@ -

- Quickgui -
- Quickgui -

+
+Quickgui -

An elegant virtual machine manager for the desktop

-
Quickgui screenshot
+# Quickgui -This project is discussed mainly on [![Discord](https://img.shields.io/discord/712850672223125565?color=87a556&label=WimpysWorld%20Discord&logo=discord&logoColor=ffffff&style=flat-square)](https://discord.gg/sNmz3uw) server +**An elegant virtual machine manager for the desktop** -## Install +**Made with 💝 for Tux (Linux)** + +
-### quickemu -For this tool to work, you need to have `quickget`, from the `quickemu` -package, in your current `path`. -Go to the `quickemu` [github page](https://github.com/quickemu-project/quickemu) -for more information about installing the tool. +

+  Discord +

-### Standard package +# Introduction -On Ubuntu, `quickgui` can be installed as a standard package. +Quickgui is a graphical user interface for the [Quickemu](https://github.com/quickemu-project/quickemu) virtual machine manager. +Quickgui enables you to create and manage virtual machines from a simple and elegant interface. +Nearly 1000 operating systems supported including Windows, macOS, BSDs, and 100s of Linux distros. All with automated downloads and configuration. -First, add this ppa (this only needs to be done once): +# Install -``` -sudo add-apt-repository ppa:yannick-mauray/quickgui -sudo apt update +Quickgui depends on Quickemu. Most package managers will automatically install Quickemu when you install Quickgui. + +If you don't have Quickemu installed then go and follow the Quickemu installation steps for your operating system: + +- [**Quickemu Installation**](https://github.com/quickemu-project/quickemu/wiki/01-Installation) + +## Debian + +A .deb package is available for Debian on our [release page](https://github.com/quickemu-project/quickgui/releases). + +- Download the latest .deb package +- Install it with `apt-get install ./quickgui-1.2.9+1-linux.deb` + +## Fedora + +A .rpm package is available for Fedora on our [release page](https://github.com/quickemu-project/quickgui/releases). + +## NixOS + +### Flake + +[![FlakeHub](https://img.shields.io/endpoint?url=https://flakehub.com/f/quickemu-project/quickgui/badge)](https://flakehub.com/flake/quickemu-project/quickgui) + +Stable releases of Quickgui are published to FlakeHub for NixOS users. See the Quickemu flake on FlakeHub for more details: + +- + +### Nixpkgs + +Add Quickgui to your `systemPackages`. For example: + +```nix +systemPackages = with pkgs; [ + quickgui +]; ``` -Then, install the package: -``` -sudo apt install quickgui +## Ubuntu + +Ubuntu users can install Quickgui using the [.deb package described above for Debian](#debian) or from our PPA. + +```shell +sudo add-apt-repository ppa:flexiondotorg/quickgui +sudo apt-get update +sudo apt-get install quickgui ``` +## Other Linux + +We provide an AppImage and a pre-compiled binary of Quickemu in a .zip file. + +### AppImage + +The AppImage should work on most Linux distributions. + +* [Download](https://github.com/quickemu-project/quickgui/releases) the latest AppImage. +* `chmod +x quickgui-1.2.9+1-linux.AppImage` +* `./quickgui-1.2.9+1-linux.AppImage` + ### Pre-compiled binary -* [Download](https://github.com/quickemu-project/quickgui/releases) the binary. -* Uncompress the tarball wherever you want. -* From anywhere on the filesystem, run the app. +* [Download](https://github.com/quickemu-project/quickgui/releases) the latest .zip file. +* `unzip quickgui-1.2.9+1-linux.zip` +* `cd quickgui-1.2.9+1-linux` +* `chmod +x quickgui` +* `./quickgui` -```bash -xz quickgui-a.b.c-d.tar.xz -tar xvf quickgui-a.b.c-d.tar -/path/to/quickgui -``` +# Compile -Alternatively, use `update-alternatives` to install `quickgui` system-wide: +To compile the Quickgui yourself: -```bash -sudo update-alternatives --install /usr/local/bin/quickgui quickgui /path/to/quickgui 50 -``` +* [Install Flutter](https://docs.flutter.dev/get-started/install/linux/desktop) +* `git clone https://github.com/quickemu-project/quickgui.git` +* `cd quickgui` +* `flutter pub get` +* `flutter config --enable-linux-desktop` +* `flutter build linux --release` -## Build +The compiled binary will be in `build/linux/x64/release/bundle/quickgui`. +You can run it with: -If you don't want to run the binary, you can rebuild the application yourself: - -* [Set up Flutter](https://ubuntu.com/blog/getting-started-with-flutter-on-ubuntu) -* Clone this repo, -* Switch to the project's directory, -* Build the project, -* Run the app. - -```bash -git clone https://github.com/quickgui/quickgui.git -cd quickgui -flutter build linux --release +```shell ./build/linux/x64/release/bundle/quickgui ``` -You can also use `update-alternatives` for easier access to the app. +# Usage -## Usage +
+Main Screen

+Quickgui Main screen +
-### Downloading VMs +## Downloader -From the main screen, select the operating system you want to use. The list can be filtered. +- From the main screen, click "Create new machines" +- Select the Operating System you want to install +- Select the Version of the operating system you want to use. +- Click the "Download" button. + - The ISO will be downloaded +- When the download is complete, click the "Dismiss" button. +
+Downloader
+Quickgui Downloader +
-
Main screen
+## Manager -
List of supported operating systems
+- From the main screen, click "Manage existing machines" +- The Manager screen will list available Quickemu VMs in the directory you have chosen to store them. +- Start a VM by clicking the "Play" (▶) button. +- Kill a running VM by clicking the "Stop" (■) button. +- Clicking the "Trash" (🗑) button will prompt you to delete the whole VM or just its disk image. -
Search a distribution
+
+Manager
+Quickgui Manager +
-Then, select the version: +When a VM is running, Quickgui will display the host ports that are mapped to the SPICE and SSH ports on the guest. These ports are used to connect to the guest for display and SSH access. -
Main screen after selection of the operating system
+### SPICE -
Versions of the selected operating system
+If you close the SPICE display and wish to reconnect, you can click the "Connect display with SPICE" button. To open an SSH session, you can click the "Connect with SSH" button. -If there are some options (Windows language, Pop!_OS nvidia or Intel, etc..), they will be displayed: +If the "Connect display with SPICE" button is disabled, the `spicy` client cannot be found. Ensure it is installed, and in your PATH (it should have been installed with `quickemu`). -
Choose an option
+### SSH -
Option is displayed
+If the "Connect with SSH" button is disabled, an SSH server cannot be detected on the guest. Most guest operating systems will not install an SSH server by default, so if it was not an option during installation, you will need to install one yourself. It must be listening on port 22 (the default SSH port). Once a server is installed and running, it should be detected automatically. -Then click "Download". The ISO will be downloaded in the current working directory, in 99% of cases that will be the directory where `quickgui` was invoked from. - -
Waiting for download
- -
Downloading
- -
Download finished
- -### Managing VMs - -The "Manage running VMs" screen will list available Quickemu VMs in the current working directory. - -VMs can be launched by clicking the "Play" (▶) button. Running VMs will have the "Play" and "Stop" buttons highlighted in green and red respectively, and pressing "Stop" (■) will kill the running VM. - -When a VM is running, the host's ports mapped to SPICE and SSH on the guest will be displayed. If you close the SPICE display and wish to reconnect, you can click the "Connect display with SPICE" button. To open an SSH session, you can click the "Connect with SSH" button. - -If the "Connect display with SPICE" button is disabled, the `spicy` client could not be found. Ensure it is installed, and in your PATH (it should have been installed with `quickemu`). - -If the "Connect with SSH" button is disabled, an SSH server could not be detected on the guest. Most guest operating systems will not install an SSH server by default, so if it was not an option during install, you will need to install one yourself. It must be listening on port 22 (the default SSH port). Once a server is installed and running, it should be detected automatically. - -"Connect with SSH" will use the terminal emulator symlinked to `x-terminal-emulator`. Several common terminal emulators are supported. If yours is not, please raise an issue on this repository. +"Connect with SSH" will open a terminal and attempt to connect to the guest. If the connection is successful, you will be prompted for the password. If the connection is unsuccessful, you might need to remove the host key for the guest from your `~/.ssh/known_hosts` file using something like `ssh-keygen -R [localhost]:22220`. diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 0000000..a632f13 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,18 @@ +# Security Policy + +## Supported Versions + +Here are the versions of Quickgui currently being supported with security updates. + +| Version | Supported | +| ------- | ------------------ | +| 1.2.x | :white_check_mark: | +| < 1.1 | :x: | + +## Reporting a Vulnerability + +If you discover a vulnerability in Quickgui then [file an issue](https://github.com/quickemu-project/quickgui/issues/new) and click *Report a vulnerability*. + +- Quickgui is a spare-time hobby project. +- We do not have SLAs for responding to security issues. +- It is a best-efforts basis. diff --git a/assets/github/screenshot1.png b/assets/github/screenshot1.png deleted file mode 100644 index e77e03f..0000000 Binary files a/assets/github/screenshot1.png and /dev/null differ diff --git a/assets/github/screenshot10.png b/assets/github/screenshot10.png deleted file mode 100644 index a4b8840..0000000 Binary files a/assets/github/screenshot10.png and /dev/null differ diff --git a/assets/github/screenshot11.png b/assets/github/screenshot11.png deleted file mode 100644 index d7301a5..0000000 Binary files a/assets/github/screenshot11.png and /dev/null differ diff --git a/assets/github/screenshot12.png b/assets/github/screenshot12.png deleted file mode 100644 index 1798135..0000000 Binary files a/assets/github/screenshot12.png and /dev/null differ diff --git a/assets/github/screenshot2.png b/assets/github/screenshot2.png deleted file mode 100644 index c5d1e0a..0000000 Binary files a/assets/github/screenshot2.png and /dev/null differ diff --git a/assets/github/screenshot3.png b/assets/github/screenshot3.png deleted file mode 100644 index e0ae29d..0000000 Binary files a/assets/github/screenshot3.png and /dev/null differ diff --git a/assets/github/screenshot4.png b/assets/github/screenshot4.png deleted file mode 100644 index ac465c3..0000000 Binary files a/assets/github/screenshot4.png and /dev/null differ diff --git a/assets/github/screenshot5.png b/assets/github/screenshot5.png deleted file mode 100644 index aab3b9a..0000000 Binary files a/assets/github/screenshot5.png and /dev/null differ diff --git a/assets/github/screenshot6.png b/assets/github/screenshot6.png deleted file mode 100644 index 507f0cc..0000000 Binary files a/assets/github/screenshot6.png and /dev/null differ diff --git a/assets/github/screenshot7.png b/assets/github/screenshot7.png deleted file mode 100644 index 6e46176..0000000 Binary files a/assets/github/screenshot7.png and /dev/null differ diff --git a/assets/github/screenshot8.png b/assets/github/screenshot8.png deleted file mode 100644 index 9765a32..0000000 Binary files a/assets/github/screenshot8.png and /dev/null differ diff --git a/assets/github/screenshot9.png b/assets/github/screenshot9.png deleted file mode 100644 index 316e2e0..0000000 Binary files a/assets/github/screenshot9.png and /dev/null differ diff --git a/assets/github/screenshot_01_main.png b/assets/github/screenshot_01_main.png new file mode 100644 index 0000000..cb81784 Binary files /dev/null and b/assets/github/screenshot_01_main.png differ diff --git a/assets/github/screenshot_02_downloader.png b/assets/github/screenshot_02_downloader.png new file mode 100644 index 0000000..295f7c3 Binary files /dev/null and b/assets/github/screenshot_02_downloader.png differ diff --git a/assets/github/screenshot_03_manager.png b/assets/github/screenshot_03_manager.png new file mode 100644 index 0000000..53af5e2 Binary files /dev/null and b/assets/github/screenshot_03_manager.png differ diff --git a/flake.lock b/flake.lock index e754ce7..e9c9284 100644 --- a/flake.lock +++ b/flake.lock @@ -16,12 +16,12 @@ }, "nixpkgs": { "locked": { - "lastModified": 1719254875, - "narHash": "sha256-ECni+IkwXjusHsm9Sexdtq8weAq/yUyt1TWIemXt3Ko=", - "rev": "2893f56de08021cffd9b6b6dfc70fd9ccd51eb60", - "revCount": 643242, + "lastModified": 1719506693, + "narHash": "sha256-C8e9S7RzshSdHB7L+v9I51af1gDM5unhJ2xO1ywxNH8=", + "rev": "b2852eb9365c6de48ffb0dc2c9562591f652242a", + "revCount": 644565, "type": "tarball", - "url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.643242%2Brev-2893f56de08021cffd9b6b6dfc70fd9ccd51eb60/0190530b-f61b-7788-9601-b336b1caf671/source.tar.gz" + "url": "https://api.flakehub.com/f/pinned/NixOS/nixpkgs/0.1.644565%2Brev-b2852eb9365c6de48ffb0dc2c9562591f652242a/01906511-d0fc-7244-b596-2d790f5bfdb0/source.tar.gz" }, "original": { "type": "tarball", diff --git a/lib/src/model/app_settings.dart b/lib/src/model/app_settings.dart index 6d4ab47..55c5626 100644 --- a/lib/src/model/app_settings.dart +++ b/lib/src/model/app_settings.dart @@ -4,10 +4,10 @@ import 'package:flutter/material.dart'; import 'package:quickgui/src/supported_locales.dart'; class AppSettings extends ChangeNotifier { - ThemeMode? _themeMode; + ThemeMode _themeMode = ThemeMode.light; String? _activeLocale; - ThemeMode get themeMode => _themeMode ?? ThemeMode.system; + ThemeMode get themeMode => _themeMode; String get activeLocale => _activeLocale ?? Platform.localeName; @@ -38,8 +38,7 @@ class AppSettings extends ChangeNotifier { } set useDarkModeSilently(bool useDarkMode) { - //_themeMode = useDarkMode ? ThemeMode.dark : ThemeMode.light; - _themeMode = ThemeMode.light; + _themeMode = useDarkMode ? ThemeMode.dark : ThemeMode.light; } set useDarkMode(bool useDarkMode) { diff --git a/lib/src/widgets/left_menu.dart b/lib/src/widgets/left_menu.dart index 4b4bcac..3f01e07 100644 --- a/lib/src/widgets/left_menu.dart +++ b/lib/src/widgets/left_menu.dart @@ -16,11 +16,15 @@ class LeftMenu extends StatefulWidget { } class _LeftMenuState extends State with PreferencesMixin { + List> _dropdownMenuItems = []; late String currentLocale; @override void initState() { super.initState(); + _dropdownMenuItems = supportedLocales + .map((e) => DropdownMenuItem(child: Text(e), value: e)) + .toList(); } @override @@ -45,21 +49,32 @@ class _LeftMenuState extends State with PreferencesMixin { child: ListView( children: [ ListTile( - title: Text("Quickgui $version", - style: Theme.of(context).textTheme.titleLarge), + title: Text("Quickgui $_version", + style: const TextStyle(fontSize: 24.0, fontWeight: FontWeight.bold)), + ), + Container( + height: 4.0, ), - /* - const Divider(), Padding( padding: const EdgeInsets.symmetric(horizontal: 16), child: Row( children: [ - Text(context.t('Use dark mode')), + Text(context.t('Use dark mode'), + style: TextStyle( + color: Colors.grey[300], + ), + ), Expanded( child: Container(), ), Switch( value: Theme.of(context).colorScheme.brightness == Brightness.dark, + onChanged: null, + activeColor: Colors.grey[300], + activeTrackColor: Colors.grey[300], + inactiveThumbColor: Colors.grey[300], + inactiveTrackColor: Colors.grey[300], + /* onChanged: (value) { appSettings.useDarkMode = value; savePreference(prefThemeMode, value); @@ -68,12 +83,14 @@ class _LeftMenuState extends State with PreferencesMixin { activeTrackColor: Colors.black26, inactiveThumbColor: Theme.of(context).colorScheme.onPrimary, inactiveTrackColor: Theme.of(context).colorScheme.primary, + */ ), ], ), ), - */ - const Divider(), + Container( + height: 4.0, + ), Padding( padding: const EdgeInsets.symmetric(horizontal: 16), child: Row( @@ -84,10 +101,7 @@ class _LeftMenuState extends State with PreferencesMixin { ), DropdownButton( value: currentLocale, - items: supportedLocales - .map( - (e) => DropdownMenuItem(value: e, child: Text(e))) - .toList(), + items: _dropdownMenuItems, onChanged: (value) { setState(() { currentLocale = value!; diff --git a/package.nix b/package.nix index 8ba1e27..dc89e31 100644 --- a/package.nix +++ b/package.nix @@ -31,8 +31,10 @@ flutter.buildFlutterApplication rec { nativeBuildInputs = [ copyDesktopItems ]; postFixup = '' - mkdir -p $out/share/pixmaps - cp $out/app/data/flutter_assets/assets/images/logo_pink.png $out/share/pixmaps/quickemu.png + for SIZE in 16 32 48 64 128 256 512; do + mkdir -p $out/share/icons/hicolor/$SIZEx$SIZE/apps/ + cp -av assets/resources/quickgui_$SIZE.png $out/share/icons/hicolor/$SIZEx$SIZE/apps/quickgui.png + done ''; desktopItems = [ @@ -41,12 +43,13 @@ flutter.buildFlutterApplication rec { exec = "quickgui"; icon = "quickgui"; desktopName = "Quickgui"; + comment = "An elegant virtual machine manager for the desktop"; categories = [ "Development" "System" ]; }) ]; meta = with lib; { - description = "Flutter frontend for quickemu"; + description = "An elegant virtual machine manager for the desktop"; homepage = "https://github.com/quickemu-project/quickgui"; changelog = "https://github.com/quickemu-project/quickgui/releases/"; license = licenses.mit; diff --git a/pubspec.yaml b/pubspec.yaml index 37a1213..cc7e9c4 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -20,7 +20,7 @@ dependencies: gettext_i18n: ^1.0.5 gettext_parser: ^0.2.0 package_info_plus: ^8.0.0 - process_run: ^0.14.2 + process_run: ^1.0.0+1 provider: ^6.1.2 quiver: ^3.2.1 url_launcher: ^6.3.0