Giter Site home page Giter Site logo

aagl-gtk-on-nix-darwin's Introduction

aagl-gtk-on-nix

Run an-anime-team launchers on Nix/NixOS!

Cachix

It's recommended to set up Cachix so you won't need to build the launchers yourself:

$ nix-shell -p cachix --run "cachix use ezkea"

Alternatively, you can add the Cachix declaratively:

# configuration.nix
{
  nix.settings = {
    substituters = [ "https://ezkea.cachix.org" ];
    trusted-public-keys = [ "ezkea.cachix.org-1:ioBmUbJTZIKsHmWWXPe1FSFbeVe+afhfgqgTSNd34eI=" ];
  };
}

Installation

To install the launchers on NixOS, refer to the following example module:

# configuration.nix
{ config, pkgs, ... }:
let
  aagl-gtk-on-nix = import (builtins.fetchTarball "https://github.com/ezKEa/aagl-gtk-on-nix/archive/main.tar.gz");
  # Or, if you follow Nixkgs release 23.11:
  # aagl-gtk-on-nix = import (builtins.fetchTarball "https://github.com/ezKEa/aagl-gtk-on-nix/archive/release-23.11.tar.gz");
  # aaglPkgs = aagl-gtk-on-nix.withNixpkgs pkgs
in
{
  imports = [
    aagl-gtk-on-nix.module
    # aaglPkgs.module
  ];

  programs.anime-game-launcher.enable = true;
  programs.anime-games-launcher.enable = true;
  programs.anime-borb-launcher.enable = true;
  programs.honkers-railway-launcher.enable = true;
  programs.honkers-launcher.enable = true;
}

The withNixpkgs function allows you change the nixpkgs instance which this package set is built against, similarly to to the inputs.nixpkgs.follows syntax in flakes. If you use NixOS on the unstable branch, it's likely that your environment is incompatible with the runtime dependencies provided by the flake-pinned nixpkgs, so you probably want to use this.

Flakes

Both the Cachix config and NixOS module are accessible via Flakes as well:

{
  inputs = {
    # Other inputs
    aagl.url = "github:ezKEa/aagl-gtk-on-nix";
    # Or, if you follow Nixkgs release 23.11:
    # aagl.url = "github:ezKEa/aagl-gtk-on-nix/release-23.11";
    aagl.inputs.nixpkgs.follows = "nixpkgs"; # Name of nixpkgs input you want to use
  };

  outputs = { self, nixpkgs, aagl, ... }: {
    nixosConfigurations.your-host = nixpkgs.lib.nixosSystem {
      system = "x86_64-linux";
      modules = [
        # Your system modules
        {
          imports = [ aagl.nixosModules.default ];
          nix.settings = aagl.nixConfig; # Set up Cachix
          programs.anime-game-launcher.enable = true; # Adds launcher and /etc/hosts rules
          programs.anime-games-launcher.enable = true;
          programs.anime-borb-launcher.enable = true;
          programs.honkers-railway-launcher.enable = true;
          programs.honkers-launcher.enable = true;
        }
      ];
    };
  };
}

Home Manager

You can also install the launchers using home-manager.

# home.nix
let
  aagl-gtk-on-nix = import (builtins.fetchTarball "https://github.com/ezKEa/aagl-gtk-on-nix/archive/main.tar.gz");
in
{
  home.packages = [
    aagl-gtk-on-nix.anime-game-launcher
    aagl-gtk-on-nix.anime-borb-launcher
    aagl-gtk-on-nix.honkers-railway-launcher
    aagl-gtk-on-nix.honkers-launcher
  ];
}

Non-NixOS

If you are not running NixOS, append the below hosts to your /etc/hosts file:

0.0.0.0 overseauspider.yuanshen.com
0.0.0.0 log-upload-os.hoyoverse.com

0.0.0.0 log-upload.mihoyo.com
0.0.0.0 uspider.yuanshen.com
0.0.0.0 sg-public-data-api.hoyoverse.com

0.0.0.0 prd-lender.cdp.internal.unity3d.com
0.0.0.0 thind-prd-knob.data.ie.unity3d.com
0.0.0.0 thind-gke-usc.prd.data.corp.unity3d.com
0.0.0.0 cdp.cloud.unity3d.com
0.0.0.0 remote-config-proxy-prd.uca.cloud.unity3d.com

then install through nix-env by running

$ nix-env -f https://github.com/ezKEa/aagl-gtk-on-nix/archive/main.tar.gz -iA anime-game-launcher

Usage

After installation, you can start the launcher by running anime-game-launcher, honkers-railway-launcher, or honkers-launcher. Have fun!

aagl-gtk-on-nix-darwin's People

Contributors

ezkea avatar github-actions[bot] avatar ludovicopiero avatar dependabot[bot] avatar yavko avatar sortofasian avatar chn-beta avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.