Make nixos usable for non-technical users through a settings / package management GUI.

Related tags

nix-gui
Overview

(Work in Progress)

Nix-Gui

Make nixos usable for non-technical users through a settings / package management GUI.

screenshots/historical_2021_06_23.gif

Motives

The declarative nature of nixos provides it the capability of being the most user friendly linux distro. No more editing dotfiles, /etc files, manually writing timers, services, running commands to manage and create users and groups, etc. Nixos integrates all of that into a declarative system, and this project integrates nixos’ declarative system into a GUI.

Serve Users Unfamiliar with, or Learning Nix

Nix-Gui is a configuration management tool designed for those who haven’t mastered the (arguably difficult) nix language. It is also an attempt to replicate the ease of use of popular configuration systems including

  • Ubuntu’s Unity System Settings
  • Mint’s Cinnimon Settings
  • Synaptic Package Manager

At the same time, Nix-Gui should serve to gradually and comfortably teach users about the mechanics of the nix language and nixpkgs. At the most advanced level, once feature parity has been achieved Nix-Gui may be considered an IDE.

Serve Mobile Users

An additional motive for this project is to enable system configuration for mobile devices without having to type code on your phone.

Docs

Contributing

Non-developers (and interested developers), if you want to help, please contact me on matrix (details below) to help with UX testing.

Developers, if you’re interested in contributing, you may

  • Review the code and point out potential improvements and flaws.
  • Review milestones and issues and create pull requests to address bugs and missing features.
  • Contribute to important dependencies including rnix-parser and rnix-lsp.
  • Contact me on matrix to discuss.

Contact

Contact me on Matrix (andrew:mtx.rew.la)

Issues
  • Implement basic save functionality

    Implement basic save functionality

    fixes https://github.com/nix-gui/nix-gui/issues/18

    Edit:

    test_load_edit_save showed a major weakness in the API: StateModels aren't independent. That is if you edit a state and persist it, loading a new StateModel will result in retrieval of the pre-edit state. This is because get_option_data is wrapped with lru_cache.

    Therefore to get the test working I stripped the lru_cache decorator. This results in redundant calculations of modules options, and the tests take over 600 seconds on my end. Therefore in this PR I will also:

    • [x] resolve https://github.com/nix-gui/nix-gui/issues/49
    • [x] write a cache decorator which checks if the contents of a file have changed, otherwise returns the cached result
    opened by lapp0 9
  • [WIP] Nix refactor

    [WIP] Nix refactor

    null

    opened by adrianparvino 4
  • Fix run commands

    Fix run commands

    The commands required to run doesn't seem to require me to use executable name (errors because nix-gui isn't a valid command argument)

    Tested on NixOS 21.11 (Porcupine) x86_64.

    opened by Lillecarl 4
  • Singleton options may be broken

    Singleton options may be broken

    https://github.com/nix-gui/nix-gui/pull/80/files#diff-d0d6622e4d148a2bd4c8868338287e7ac39d8c1a3c6da3b46f4841f9ae2323fcR61-R67

    2021-08-12-004135_1920x1050_scrot

    opened by adrianparvino 4
  • How to run it ?

    How to run it ?

    Hi

    I just tried to run it, but it didn't work

    nixFlakes run github:lapp0/nix-gui
    warning: ignoring the user-specified setting 'experimental-features', because it is a restricted setting and you are not a trusted user
    Traceback (most recent call last):
      File "/nix/store/q3yrkldj3jh44z1n4w6i8pa50jcs0sii-python3.8-nix-gui-0.1.0/bin/.nix-gui-wrapped", line 9, in <module>
        sys.exit(main())
      File "/nix/store/q3yrkldj3jh44z1n4w6i8pa50jcs0sii-python3.8-nix-gui-0.1.0/lib/python3.8/site-packages/nixui/gui.py", line 66, in main
        statemodel = state_model.StateModel()
      File "/nix/store/q3yrkldj3jh44z1n4w6i8pa50jcs0sii-python3.8-nix-gui-0.1.0/lib/python3.8/site-packages/nixui/state_model.py", line 14, in __init__
        for opt in api.get_options_dict().keys()
      File "/nix/store/q3yrkldj3jh44z1n4w6i8pa50jcs0sii-python3.8-nix-gui-0.1.0/lib/python3.8/site-packages/nixui/api.py", line 13, in get_options_dict
        res = json.load(open('./release_out/share/doc/nixos/options.json'))
    FileNotFoundError: [Errno 2] No such file or directory: './release_out/share/doc/nixos/options.json'
    

    What should I do to be able to run it ?

    opened by pinage404 3
  • Implement Attribute Set

    Implement Attribute Set

    • [x] Implement OptionTable for lookup, addition, and deletion of options
    • [x] All tests pass
    • [x] AttributeSetOf proper functioning including loading (fixes https://github.com/nix-gui/nix-gui/issues/29)

    Note: OptionTabs was also disabled in this PR

    Further improvements left to https://github.com/nix-gui/nix-gui/issues/72

    opened by lapp0 3
  • Use makeWrapperArgs to inject rnix

    Use makeWrapperArgs to inject rnix

    opened by adrianparvino 3
  • QT Window not opening when running with basic config

    QT Window not opening when running with basic config

    Calling CONFIGURATION_PATH=/etc/nixos/configuration.nix nix run github:lapp0/nix-gui with minimal config leads to a qt window being opened for the fraction of a second and then aborting with an error. Qtile is installed with home manager and works with other applications.

    Config I tried to use:

    { config, pkgs, ... }:
    
    {
      imports =
        [
          ./hardware-configuration.nix
        ];
    
      boot.loader.systemd-boot.enable = true;
      boot.loader.efi.canTouchEfiVariables = true;
      nixpkgs.config.allowUnfree = true;
    
      networking.hostName = "nixos"; # Define your hostname.
    
      time.timeZone = "Europe/Berlin";
    
      networking.useDHCP = false;
      networking.interfaces.enp0s31f6.useDHCP = true;
    
      i18n.defaultLocale = "en_US.UTF-8";
      console = {
        font = "Lat2-Terminus16";
        keyMap = "us";
      };
    
      services.xserver.enable = true;
      services.xserver.displayManager.sddm.enable = true;
      services.xserver.desktopManager.plasma5.enable = true;
    
    
      services.xserver.layout = "us";
      services.xserver.xkbOptions = "eurosign:e";
    
      services.printing.enable = true;
    
      sound.enable = true;
      hardware.pulseaudio.enable = true;
    
    
      users.users.vincenzo = {
        isNormalUser = true;
        initialPassword = "password";
        extraGroups = [ "wheel" ];
      };
    
      services.openssh.enable = true;
      system.autoUpgrade = {
    	enable = true;
      };
      system.stateVersion = "20.09";
    
      nix = {
    	trustedUsers = [ "root" "vincenzo" ];
      };
    }
    

    Error message I received:

    Traceback (most recent call last):
      File "/nix/store/fdazal8y5az6vg0z5r8d6wb82ys4j5pi-python3.8-nix-gui-0.1.0/lib/python3.8/site-packages/nixui/richtext.py", line 15, in paint
        textRect = style.subElementRect(QtWidgets.QStyle.SE_ItemViewItemText, option)
    TypeError: subElementRect(self, QStyle.SubElement, QStyleOption, QWidget): not enough arguments
    Aborted (core dumped)
    
    opened by DerDoni 3
  • Setup Basic Integration Test

    Setup Basic Integration Test

    implement testing

    fixes https://github.com/lapp0/nix-gui/issues/15

    opened by lapp0 2
  • WIP: Fix Set Modules Issue

    WIP: Fix Set Modules Issue

    Fixes #54

    • [x] fix test case so it correctly fails if set module is used
    • [x] minor improvements to code and tests
    • [ ] import set module

    Currently the evalModuleStub changes result in no position being returned.

    Error for set modules before this change:

    E               error: while evaluating 'get_modules_defined_attrs' at /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:48:31, called from (string):1:1:
    E               while evaluating 'collectDeclarationPositions' at /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:12:42, called from /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:55:5:
    E               while evaluating 'evalModuleStub' at /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:21:20, called from /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:53:36:
    E               attempt to call something which is not a function but a set, at /build/k204x5pv8a4s0ach7h0g08wibc09gdgd-source/nixui/nix/lib.nix:21:33
    
    

    Output before this change:

    [{'loc': ['environment', 'etc'], 'position': {'column': 3, 'file': '/build/ffjx8jqw8fn6ijcqdd0nrqrcb5x73gja-source/nixui/tests/sample/configuration.nix', 'line': 104}}, {'loc': ['environment', 'systemPackages'], 'position': {'column': 3, 'file': '/build/ffjx8jqw8fn6ijcqdd0nrqrcb5x73gja-source/nixui/tests/sample/configuration.nix', 'line': 167}}...
    

    Output after this change:

    [{'loc': ['appstream', 'enable'], 'position': None}, {'loc': ['assertions'], 'position': None}
    

    Need to look more into how https://github.com/NixOS/nixpkgs/blob/master/nixos/lib/eval-config.nix and https://github.com/NixOS/nixpkgs/blob/a3df3d05e5db17b26ff886f53a58761a547561cc/lib/modules.nix works to fix this issue and merge.

    opened by lapp0 0
  • [WIP] Add FloatField

    [WIP] Add FloatField

    Fixes issue #52 but not sure if it works fully.

    opened by boredom101 1
  • Improve look and feel for dark themes

    Improve look and feel for dark themes

    https://stackoverflow.com/questions/48256772/dark-theme-for-qt-widgets/48256803#48256803

    https://github.com/nix-gui/nix-gui/issues/129#issuecomment-940381243

    opened by lapp0 0
  • UX Survey

    UX Survey

    Please answer any of following questions in the comment section below:

    1. Under what name or alias would you like to be credited for your answers? (Default/unanswered = "anonymous")

    2. What would you would change about how Nix-Gui behaves?

    3. What functionality would you expect Nix-Gui to have that it doesn't?

    4. What is the most difficult part of finding / editing an option?

    5. What non-obvious behavior did you encounter when using Nix-Gui?

    6. What other question should I ask in this survey (and what is your answer?)

    opened by lapp0 4
  • profile navlist color selection and optimize

    profile navlist color selection and optimize

    Navlist colors are set based on whether the option or a descendant is changed either in configuration or in memory. This is operation more expensive than it should be.

    opened by lapp0 0
  • display correct number of descendants

    display correct number of descendants

    get correct number of children (e.g. options:sound is wrong, says 4, is really 5), meaning it's looking at direct children, not descendants

    opened by lapp0 0
  • Change type of path in navbar

    Change type of path in navbar

    select undefined, expression, or reference via dropdown for selected path in navbar.

    opened by lapp0 0
  • Implement CHECK DESCENDANTS

    Implement CHECK DESCENDANTS

    null

    opened by lapp0 0
  • Option

    Option "Example" in ToolTip

    Currently options have description and type metadata in the ToolTip. We should also include the example from nixpkgs

    good first issue 
    opened by lapp0 0
  • Preferences

    Preferences

    • Preferences should have a similar structure to nixos options.
    • Preferences should be displayable with the same navlist and option_display that options are shown with.
    • Configuration templates (https://github.com/nix-gui/nix-gui/issues/77) should be able to combine options with prefrences.
      • for example, a template to start an SSH server should be able to accept nixops-relevant credentials via nixui.preferences.nixops.<credential paths>, along with the parameters of the ssh server they want to deploy
    opened by lapp0 0
Use NixOS Without Coding

(Work in Progress) Nix-Gui Make NixOS usable for non-technical users through a settings / package management GUI. Motives The declarative nature of Ni

null 422 Oct 21, 2021
Make nixos usable for non-technical users through a settings / package management GUI.

Nix-Gui Make nixos usable for non-technical users through a settings / package management GUI. Motives The declarative nature of ni

null 407 Oct 16, 2021
A GUI for designing Python GUI's for PySimpleGUI.

SimpleGUIBuilder A GUI for designing Python GUI's for PySimpleGUI. Installation There is none :) just download the file from a release and run it. Don

Miguel Martins 50 Oct 16, 2021
guietta - a tool for making simple Python GUIs

guietta - a tool for making simple Python GUIs

Alfio Puglisi 1.8k Oct 20, 2021
Turn (almost) any Python command line program into a full GUI application with one line

Gooey Turn (almost) any Python 2 or 3 Console Program into a GUI application with one line Support this project Table of Contents Gooey Table of conte

Chris 15k Oct 22, 2021
Edifice: a declarative GUI library for Python

Edifice is a Python library for building reactive UI, inspired by modern Javascript libraries such as React.

David Ding 77 Oct 9, 2021
GlobalProtectGUI is a simple tray app to connect, disconnect and monitor globalprotect VPN connection.

Simple GlobalProtectGUI GlobalProtectGUI is simple tray app to connect, disconnect and monitor globalprotect VPN connection. Installation Required bef

Aleksandar Dostic 6 Sep 7, 2021
GUI for Volatility forensics tool written in PyQT5

Volatility GUI This is a GUI for Volatility forensics tool written in PyQT5 Prerequisites: 1- Installed version of Volatility. 2- Install PyQT5. sudo

Hamza Megahed 52 Oct 21, 2021
OpenPort scanner GUI tool (CNMAP)

CNMAP-GUI- OpenPort scanner GUI tool (CNMAP) as you know it is the advanced tool to find open port, firewalls and we also added here heartbleed scanni

null 3 Oct 20, 2021
Aplicação GUI feita em Python para estudos de cadastro (forms).

Cadastro de DEVs GUI ?? A ideia original veio do repositório do https://github.com/PedroTomazeti nomeado 'Projetos-Independentes-HTML-CSS' Nele há um

Yago Goltara 3 Aug 15, 2021
A little Python library for making simple Electron-like HTML/JS GUI apps

Eel Eel is a little Python library for making simple Electron-like offline HTML/JS GUI apps, with full access to Python capabilities and libraries. Ee

Chris Knott 4.6k Oct 22, 2021
Declarative User Interfaces for Python

Welcome to Enaml Enaml is a programming language and framework for creating professional-quality user interfaces with minimal effort. What you get A d

null 1.1k Oct 15, 2021
Tkinter Designer - Create Beautiful Tkinter GUIs by Drag and Drop.

Tkinter Designer is created to speed up and beautify Python GUI Experience. It uses well know design software called Figma. Which makes creating Tkinter GUI in Python a piece of cake.

Parth Jadhav 2.7k Oct 24, 2021
A Python Tkinter based Inventory managment System

Inventory Management System Using Python Tkinter Introduction Inventory managemrnt system is an open source platform for manage business. It has a com

Amit Kumar Datta 2 Oct 14, 2021
Build GUI for your Python program with JavaScript, HTML, and CSS

https://pywebview.flowrl.com pywebview is a lightweight cross-platform wrapper around a webview component that allows to display HTML content in its o

Roman 2.6k Oct 21, 2021
A small pomodoro GUI for Windows/Linux created in Python with PyQt5.

Pomodoro A small pomodoro GUI for Windows/Linux created with PyQt5. Features The "Timer" tab allows you to set your desired work and rest times aswell

Burak Martin 73 Oct 10, 2021
Learn to build a Python Desktop GUI app using pywebview, Python, JavaScript, HTML, & CSS.

Python Desktop App Learn how to make a desktop GUI application using Python, JavaScript, HTML, & CSS all thanks to pywebview. pywebview is essentially

Coding For Entrepreneurs 34 Oct 8, 2021
Dear PyGui: A fast and powerful Graphical User Interface Toolkit for Python with minimal dependencies

(This library is available under a free and permissive license however, if you Enjoy Dear PyGui please consider becoming a Sponsor) Dear PyGui is a si

Jonathan Hoffstadt 6.2k Oct 22, 2021
Dear PyGui: A fast and powerful Graphical User Interface Toolkit for Python with minimal dependencies

(This library is available under a free and permissive license however, if you Enjoy Dear PyGui please consider becoming a Sponsor) Dear PyGui is a si

Jonathan Hoffstadt 6.2k Oct 23, 2021