Compare commits
	
		
			124 Commits
		
	
	
		
			jetbrains
			...
			59f910fe3f
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						
						
							
						
						59f910fe3f
	
				 | 
					
					
						|||
| 
						
						
							
						
						93b6195542
	
				 | 
					
					
						|||
| 
						 | 
					029f6e7795 | ||
| 
						 | 
					19eb6aefbe | ||
| 
						 | 
					26b35fa847 | ||
| 
						 | 
					ec92a006c3 | ||
| 
						 | 
					622b3cbdfe | ||
| 
						
						
							
						
						6be9b3fd57
	
				 | 
					
					
						|||
| 
						 | 
					1991f762ff | ||
| 
						 | 
					7ef07f63fb | ||
| 
						
						
							
						
						9aace44d90
	
				 | 
					
					
						|||
| 
						
						
							
						
						a7e7286d6e
	
				 | 
					
					
						|||
| 
						
						
							
						
						f407a90461
	
				 | 
					
					
						|||
| 
						 | 
					9416bec1d7 | ||
| 
						 | 
					104c9a0747 | ||
| 
						 | 
					b986324ca8 | ||
| 
						 | 
					34b7a0d308 | ||
| 
						 | 
					10c372b1e3 | ||
| 
						 | 
					af1f94f029 | ||
| 
						
						
							
						
						43236beb53
	
				 | 
					
					
						|||
| 
						 | 
					1f97131fc1 | ||
| 
						 | 
					a7195c6042 | ||
| 
						 | 
					8e77024084 | ||
| 
						
						
							
						
						dfd1f1720d
	
				 | 
					
					
						|||
| 
						
						
							
						
						5531e40958
	
				 | 
					
					
						|||
| 
						
						
							
						
						267995206a
	
				 | 
					
					
						|||
| 
						
						
							
						
						a2fbb58011
	
				 | 
					
					
						|||
| 
						
						
							
						
						3d79b690e4
	
				 | 
					
					
						|||
| 
						 | 
					5f205a48c2 | ||
| 
						 | 
					7de26a6d71 | ||
| 
						 | 
					97ca7a2f35 | ||
| 
						 | 
					734650a80a | ||
| 
						 | 
					0d269dba16 | ||
| 
						 | 
					8f2e2d2372 | ||
| 
						
						
							
						
						7a84f381fc
	
				 | 
					
					
						|||
| 
						
						
							
						
						698ad1803d
	
				 | 
					
					
						|||
| 
						 | 
					896b46b2f4 | ||
| 
						 | 
					16c3c01730 | ||
| 
						 | 
					26f6048226 | ||
| 
						 | 
					69bc4e5e49 | ||
| 
						 | 
					8c691f457a | ||
| 
						 | 
					ea79df8fbf | ||
| 
						 | 
					bfc5062bb6 | ||
| 
						 | 
					2df4be1363 | ||
| 
						 | 
					4b69efc799 | ||
| 
						 | 
					9898d8265c | ||
| 
						 | 
					509a3f9918 | ||
| 
						 | 
					93bdded413 | ||
| 
						 | 
					f6fe0ddb84 | ||
| 
						 | 
					803f73b8b8 | ||
| 
						
						
							
						
						bced319f32
	
				 | 
					
					
						|||
| 
						 | 
					a798e65465 | ||
| 
						
						
							
						
						d36de346ad
	
				 | 
					
					
						|||
| 
						
						
							
						
						b7f88d78b5
	
				 | 
					
					
						|||
| 
						
						
							
						
						71f6ac0f46
	
				 | 
					
					
						|||
| 
						
						
							
						
						561afaf18c
	
				 | 
					
					
						|||
| 
						
						
							
						
						f0dc2d521d
	
				 | 
					
					
						|||
| 
						
						
							
						
						4586c00f4e
	
				 | 
					
					
						|||
| 
						 | 
					162045b8d7 | ||
| 
						
						
							
						
						fc1f1b328b
	
				 | 
					
					
						|||
| 
						 | 
					4be1dd48ce | ||
| 
						
						
							
						
						8bbc8afb15
	
				 | 
					
					
						|||
| 
						
						
							
						
						6faef6e0ac
	
				 | 
					
					
						|||
| 
						
						
							
						
						29516dc3d8
	
				 | 
					
					
						|||
| 
						 | 
					a2f24f4591 | ||
| 
						
						
							
						
						8f34b7a6fa
	
				 | 
					
					
						|||
| 
						
						
							
						
						5410671050
	
				 | 
					
					
						|||
| 
						
						
							
						
						e053da240d
	
				 | 
					
					
						|||
| 
						
						
							
						
						d0e26ddb24
	
				 | 
					
					
						|||
| 
						
						
							
						
						2efddce7c5
	
				 | 
					
					
						|||
| 
						
						
							
						
						3d8a9cfa9a
	
				 | 
					
					
						|||
| 
						
						
							
						
						782b05c59e
	
				 | 
					
					
						|||
| 
						
						
							
						
						67adbe7089
	
				 | 
					
					
						|||
| 
						
						
							
						
						5399368853
	
				 | 
					
					
						|||
| 
						
						
							
						
						ec62dc7950
	
				 | 
					
					
						|||
| 
						
						
							
						
						f20db9aa1b
	
				 | 
					
					
						|||
| 
						
						
							
						
						b21cbda697
	
				 | 
					
					
						|||
| 
						
						
							
						
						ada5f02f08
	
				 | 
					
					
						|||
| 
						 | 
					c387334fa5 | ||
| 
						 | 
					57711572f6 | ||
| 
						
						
							
						
						a83dcb3ed5
	
				 | 
					
					
						|||
| 
						
						
							
						
						a70a0e914b
	
				 | 
					
					
						|||
| 46b331a413 | |||
| 
						
						
							
						
						b8e4f0929a
	
				 | 
					
					
						|||
| 
						
						
							
						
						85aebac63d
	
				 | 
					
					
						|||
| 
						 | 
					0254963dec | ||
| 
						 | 
					0b3995a7e3 | ||
| 7414d45aa4 | |||
| ee0cf26f5b | |||
| 
						 | 
					658b1fa08c | ||
| 
						 | 
					fc33441151 | ||
| 
						
						
							
						
						0bb9971c38
	
				 | 
					
					
						|||
| 
						
						
							
						
						1530197670
	
				 | 
					
					
						|||
| 
						
						
							
						
						2c575d6596
	
				 | 
					
					
						|||
| 
						 | 
					5648d1d005 | ||
| 
						 | 
					d97d0fc259 | ||
| f5adcca761 | |||
| 6d3581ac49 | |||
| 94be83c704 | |||
| fe773352f5 | |||
| 311fb3ff98 | |||
| 260db819e7 | |||
| ba5c904cb7 | |||
| f616baa7b2 | |||
| 
						 | 
					d1ad137626 | ||
| 0335b240b6 | |||
| 
						 | 
					7edffe7e56 | ||
| 
						
						
							
						
						f218f59184
	
				 | 
					
					
						|||
| 
						
						
							
						
						1b190f8a81
	
				 | 
					
					
						|||
| 
						
						
							
						
						f7f4206afa
	
				 | 
					
					
						|||
| 
						 | 
					
						
						
							
						
						ca67f392b5
	
				 | 
					
					
						||
| 
						 | 
					
						
						
							
						
						3ce504e445
	
				 | 
					
					
						||
| 
						 | 
					
						
						
							
						
						58abb0d562
	
				 | 
					
					
						||
| 
						
						
							
						
						2cf1b51843
	
				 | 
					
					
						|||
| 
						
						
							
						
						d8ae11352e
	
				 | 
					
					
						|||
| 
						
						
							
						
						7078ef0677
	
				 | 
					
					
						|||
| 
						
						
							
						
						b2c0121005
	
				 | 
					
					
						|||
| 
						
						
							
						
						cf95fb9600
	
				 | 
					
					
						|||
| 
						
						
							
						
						3c27e38073
	
				 | 
					
					
						|||
| 
						 | 
					86f1713639 | ||
| 
						
						
							
						
						3dbd760954
	
				 | 
					
					
						|||
| 
						
						
							
						
						8b290acc50
	
				 | 
					
					
						|||
| 
						
						
							
						
						b960c361a9
	
				 | 
					
					
						|||
| 
						 | 
					0c87ddac9e | 
							
								
								
									
										2
									
								
								.github/dependabot.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/dependabot.yml
									
									
									
									
										vendored
									
									
								
							@@ -4,3 +4,5 @@ updates:
 | 
				
			|||||||
    directory: "/"
 | 
					    directory: "/"
 | 
				
			||||||
    schedule:
 | 
					    schedule:
 | 
				
			||||||
      interval: "weekly"
 | 
					      interval: "weekly"
 | 
				
			||||||
 | 
					    commit-message:
 | 
				
			||||||
 | 
					      prefix: "ci"
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										46
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										46
									
								
								.github/workflows/build.yml
									
									
									
									
										vendored
									
									
								
							@@ -1,14 +1,26 @@
 | 
				
			|||||||
name: "Build and populate cache"
 | 
					name: "CI"
 | 
				
			||||||
on:
 | 
					on:
 | 
				
			||||||
  pull_request:
 | 
					  pull_request:
 | 
				
			||||||
  push:
 | 
					  push:
 | 
				
			||||||
  schedule:
 | 
					 | 
				
			||||||
    # rebuild everyday at 6:50
 | 
					 | 
				
			||||||
    # TIP: Choose a random time here so not all repositories are build at once:
 | 
					 | 
				
			||||||
    # https://www.random.org/clock-times/?num=1&earliest=01%3A00&latest=08%3A00&interval=5&format=html&rnd=new
 | 
					 | 
				
			||||||
    - cron:  '50 6 * * *'
 | 
					 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  tests:
 | 
					
 | 
				
			||||||
 | 
					  checks:
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      matrix:
 | 
				
			||||||
 | 
					        check:
 | 
				
			||||||
 | 
					          - nixpkgs-fmt
 | 
				
			||||||
 | 
					          - deadnix
 | 
				
			||||||
 | 
					          - nur
 | 
				
			||||||
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout repository
 | 
				
			||||||
 | 
					        uses: actions/checkout@v4
 | 
				
			||||||
 | 
					      - uses: cachix/install-nix-action@v23
 | 
				
			||||||
 | 
					      - name: Check ${{ matrix.check }}
 | 
				
			||||||
 | 
					        # Depends on nixos/nix#7759 to simply `nix flake check`
 | 
				
			||||||
 | 
					        run: nix run .#checks.$(nix eval --raw --impure --expr "builtins.currentSystem").${{ matrix.check }}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  build-and-update:
 | 
				
			||||||
    strategy:
 | 
					    strategy:
 | 
				
			||||||
      matrix:
 | 
					      matrix:
 | 
				
			||||||
        # Set this to notify the global nur package registry that changes are
 | 
					        # Set this to notify the global nur package registry that changes are
 | 
				
			||||||
@@ -28,30 +40,22 @@ jobs:
 | 
				
			|||||||
        # in your repository settings in Github found at https://github.com/<your_githubname>/nur-packages/settings/secrets
 | 
					        # in your repository settings in Github found at https://github.com/<your_githubname>/nur-packages/settings/secrets
 | 
				
			||||||
        cachixName:
 | 
					        cachixName:
 | 
				
			||||||
          - xeals
 | 
					          - xeals
 | 
				
			||||||
        nixPath:
 | 
					 | 
				
			||||||
          - nixpkgs=channel:nixos-unstable
 | 
					 | 
				
			||||||
          - nixpkgs=channel:nixpkgs-unstable
 | 
					 | 
				
			||||||
          # Disable due to buildGoModule and buildRustPackage
 | 
					 | 
				
			||||||
          # - nixpkgs=channel:nixos-20.03
 | 
					 | 
				
			||||||
    runs-on: ubuntu-latest
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
    - name: Checkout repository
 | 
					    - name: Checkout repository
 | 
				
			||||||
      uses: actions/checkout@v2.3.4
 | 
					      uses: actions/checkout@v4
 | 
				
			||||||
    - name: Install nix
 | 
					    - name: Install nix
 | 
				
			||||||
      uses: cachix/install-nix-action@v12
 | 
					      uses: cachix/install-nix-action@v23
 | 
				
			||||||
      with:
 | 
					 | 
				
			||||||
        nix_path: "${{ matrix.nixPath }}"
 | 
					 | 
				
			||||||
    - name: Show nixpkgs version
 | 
					    - name: Show nixpkgs version
 | 
				
			||||||
      run: nix-instantiate --eval -E '(import <nixpkgs> {}).lib.version'
 | 
					      run: nix eval --impure --expr '(import ./flake-compat.nix { src = ./.; }).lib.version'
 | 
				
			||||||
    - name: Setup cachix
 | 
					    - name: Setup cachix
 | 
				
			||||||
      uses: cachix/cachix-action@v8
 | 
					      uses: cachix/cachix-action@v12
 | 
				
			||||||
      if: ${{ matrix.cachixName != '<YOUR_CACHIX_NAME>' }}
 | 
					      if: ${{ matrix.cachixName != '<YOUR_CACHIX_NAME>' }}
 | 
				
			||||||
      with:
 | 
					      with:
 | 
				
			||||||
        name: ${{ matrix.cachixName }}
 | 
					        name: ${{ matrix.cachixName }}
 | 
				
			||||||
        signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
 | 
					        signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
 | 
				
			||||||
    - name: Build nix packages
 | 
					    - name: Build nix packages
 | 
				
			||||||
      # TODO switch to default nixpkgs channel once nix-build-uncached 1.0.0 is in stable
 | 
					      run: nix develop .#ci -c nix-build-uncached ci.nix -A cacheOutputs
 | 
				
			||||||
      run: nix run -I 'nixpkgs=channel:nixos-unstable' nixpkgs.nix-build-uncached -c nix-build-uncached ci.nix -A cacheOutputs
 | 
					 | 
				
			||||||
    - name: Trigger NUR update
 | 
					    - name: Trigger NUR update
 | 
				
			||||||
      if: ${{ matrix.nurRepo != '<YOUR_REPO_NAME>' }}
 | 
					      if: ${{ matrix.nurRepo != '<YOUR_REPO_NAME>' }}
 | 
				
			||||||
      run: curl -XPOST "https://nur-update.herokuapp.com/update?repo=${{ matrix.nurRepo }}"
 | 
					      run: curl -XPOST "https://nur-update.nix-community.org/update?repo=${{ matrix.nurRepo }}"
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										24
									
								
								.github/workflows/update.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								.github/workflows/update.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
				
			|||||||
 | 
					name: "Update flake inputs"
 | 
				
			||||||
 | 
					on:
 | 
				
			||||||
 | 
					  workflow_dispatch:
 | 
				
			||||||
 | 
					  schedule:
 | 
				
			||||||
 | 
					    # bump weekly at 6:50
 | 
				
			||||||
 | 
					    - cron:  '50 6 * * 1'
 | 
				
			||||||
 | 
					jobs:
 | 
				
			||||||
 | 
					  update-flake:
 | 
				
			||||||
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    strategy:
 | 
				
			||||||
 | 
					      fail-fast: false
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					      - name: Checkout repository
 | 
				
			||||||
 | 
					        uses: actions/checkout@v4
 | 
				
			||||||
 | 
					      - uses: cachix/install-nix-action@v23
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          extra_nix_config: |
 | 
				
			||||||
 | 
					            access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
 | 
				
			||||||
 | 
					      - name: "flake: update inputs"
 | 
				
			||||||
 | 
					        uses: DeterminateSystems/update-flake-lock@v20
 | 
				
			||||||
 | 
					        with:
 | 
				
			||||||
 | 
					          pr-title: "flake: update inputs"
 | 
				
			||||||
 | 
					          pr-labels: dependencies
 | 
				
			||||||
 | 
					          commit-msg: "flake: update inputs"
 | 
				
			||||||
@@ -2,7 +2,7 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
**My personal [NUR](https://github.com/nix-community/NUR) repository**
 | 
					**My personal [NUR](https://github.com/nix-community/NUR) repository**
 | 
				
			||||||
 | 
					
 | 
				
			||||||
[](https://github.com/xeals/nur-packages/actions) [](https://xeals.cachix.org)
 | 
					[](https://github.com/xeals/nur-packages/actions) [](https://xeals.cachix.org)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
## Noteworthy packages
 | 
					## Noteworthy packages
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										16
									
								
								ci.nix
									
									
									
									
									
								
							
							
						
						
									
										16
									
								
								ci.nix
									
									
									
									
									
								
							@@ -9,7 +9,7 @@
 | 
				
			|||||||
# then your CI will be able to build and cache only those packages for
 | 
					# then your CI will be able to build and cache only those packages for
 | 
				
			||||||
# which this is possible.
 | 
					# which this is possible.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{ pkgs ? import <nixpkgs> {} }:
 | 
					{ pkgs ? import ./flake-compat.nix { src = ./.; } }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
with builtins;
 | 
					with builtins;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -29,10 +29,10 @@ let
 | 
				
			|||||||
    let
 | 
					    let
 | 
				
			||||||
      f = p:
 | 
					      f = p:
 | 
				
			||||||
        if shouldRecurseForDerivations p then flattenPkgs p
 | 
					        if shouldRecurseForDerivations p then flattenPkgs p
 | 
				
			||||||
        else if isDerivation p then [p]
 | 
					        else if isDerivation p then [ p ]
 | 
				
			||||||
        else [];
 | 
					        else [ ];
 | 
				
			||||||
    in
 | 
					    in
 | 
				
			||||||
      concatMap f (attrValues s);
 | 
					    concatMap f (attrValues s);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  outputsOf = p: map (o: p.${o}) p.outputs;
 | 
					  outputsOf = p: map (o: p.${o}) p.outputs;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -40,10 +40,10 @@ let
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  nurPkgs =
 | 
					  nurPkgs =
 | 
				
			||||||
    flattenPkgs
 | 
					    flattenPkgs
 | 
				
			||||||
    (listToAttrs
 | 
					      (listToAttrs
 | 
				
			||||||
    (map (n: nameValuePair n nurAttrs.${n})
 | 
					        (map (n: nameValuePair n nurAttrs.${n})
 | 
				
			||||||
    (filter (n: !isReserved n)
 | 
					          (filter (n: !isReserved n)
 | 
				
			||||||
    (attrNames nurAttrs))));
 | 
					            (attrNames nurAttrs))));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
in
 | 
					in
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -7,9 +7,11 @@
 | 
				
			|||||||
#     nix-build -A mypackage
 | 
					#     nix-build -A mypackage
 | 
				
			||||||
 | 
					
 | 
				
			||||||
{ pkgs ? import <nixpkgs> { } }:
 | 
					{ pkgs ? import <nixpkgs> { } }:
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
import ./pkgs/top-level/all-packages.nix { inherit pkgs; }
 | 
					  system = pkgs.stdenv.hostPlatform.system;
 | 
				
			||||||
  // {
 | 
					  packages = import ./pkgs/top-level { localSystem = system; inherit pkgs; };
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					packages // {
 | 
				
			||||||
  # The `lib`, `modules`, and `overlay` names are special
 | 
					  # The `lib`, `modules`, and `overlay` names are special
 | 
				
			||||||
  lib = import ./lib { inherit pkgs; }; # functions
 | 
					  lib = import ./lib { inherit pkgs; }; # functions
 | 
				
			||||||
  modules = import ./modules; # NixOS modules
 | 
					  modules = import ./modules; # NixOS modules
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										12
									
								
								flake-compat.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								flake-compat.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
				
			|||||||
 | 
					{ src, system ? builtins.currentSystem or "unknown-system" }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					  lockFilePath = "${src}/flake.lock";
 | 
				
			||||||
 | 
					  lockFile = builtins.fromJSON (builtins.readFile lockFilePath);
 | 
				
			||||||
 | 
					  nixpkgs = lockFile.nodes.nixpkgs.locked;
 | 
				
			||||||
 | 
					  tarball = fetchTarball {
 | 
				
			||||||
 | 
					    url = "https://github.com/${nixpkgs.owner}/${nixpkgs.repo}/archive/${nixpkgs.rev}.zip";
 | 
				
			||||||
 | 
					    sha256 = nixpkgs.narHash;
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					import tarball { inherit system; }
 | 
				
			||||||
							
								
								
									
										30
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										30
									
								
								flake.lock
									
									
									
										generated
									
									
									
								
							@@ -1,12 +1,15 @@
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
  "nodes": {
 | 
					  "nodes": {
 | 
				
			||||||
    "flake-utils": {
 | 
					    "flake-utils": {
 | 
				
			||||||
 | 
					      "inputs": {
 | 
				
			||||||
 | 
					        "systems": "systems"
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1605370193,
 | 
					        "lastModified": 1694529238,
 | 
				
			||||||
        "narHash": "sha256-YyMTf3URDL/otKdKgtoMChu4vfVL3vCMkRqpGifhUn0=",
 | 
					        "narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=",
 | 
				
			||||||
        "owner": "numtide",
 | 
					        "owner": "numtide",
 | 
				
			||||||
        "repo": "flake-utils",
 | 
					        "repo": "flake-utils",
 | 
				
			||||||
        "rev": "5021eac20303a61fafe17224c087f5519baed54d",
 | 
					        "rev": "ff7b65b44d01cf9ba6a71320833626af21126384",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@@ -17,11 +20,11 @@
 | 
				
			|||||||
    },
 | 
					    },
 | 
				
			||||||
    "nixpkgs": {
 | 
					    "nixpkgs": {
 | 
				
			||||||
      "locked": {
 | 
					      "locked": {
 | 
				
			||||||
        "lastModified": 1611414562,
 | 
					        "lastModified": 1694948089,
 | 
				
			||||||
        "narHash": "sha256-u002KfYA7Uk3vffnnmLz88BmxOzixYFdh+8II6ZT+Kg=",
 | 
					        "narHash": "sha256-d2B282GmQ9o8klc22/Rbbbj6r99EnELQpOQjWMyv0rU=",
 | 
				
			||||||
        "owner": "NixOS",
 | 
					        "owner": "NixOS",
 | 
				
			||||||
        "repo": "nixpkgs",
 | 
					        "repo": "nixpkgs",
 | 
				
			||||||
        "rev": "9d6fd2ba135c5b5c85c3332604d39b43e93b8298",
 | 
					        "rev": "5148520bfab61f99fd25fb9ff7bfbb50dad3c9db",
 | 
				
			||||||
        "type": "github"
 | 
					        "type": "github"
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      "original": {
 | 
					      "original": {
 | 
				
			||||||
@@ -36,6 +39,21 @@
 | 
				
			|||||||
        "flake-utils": "flake-utils",
 | 
					        "flake-utils": "flake-utils",
 | 
				
			||||||
        "nixpkgs": "nixpkgs"
 | 
					        "nixpkgs": "nixpkgs"
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "systems": {
 | 
				
			||||||
 | 
					      "locked": {
 | 
				
			||||||
 | 
					        "lastModified": 1681028828,
 | 
				
			||||||
 | 
					        "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
 | 
				
			||||||
 | 
					        "owner": "nix-systems",
 | 
				
			||||||
 | 
					        "repo": "default",
 | 
				
			||||||
 | 
					        "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
 | 
				
			||||||
 | 
					        "type": "github"
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      "original": {
 | 
				
			||||||
 | 
					        "owner": "nix-systems",
 | 
				
			||||||
 | 
					        "repo": "default",
 | 
				
			||||||
 | 
					        "type": "github"
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  },
 | 
					  },
 | 
				
			||||||
  "root": "root",
 | 
					  "root": "root",
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										99
									
								
								flake.nix
									
									
									
									
									
								
							
							
						
						
									
										99
									
								
								flake.nix
									
									
									
									
									
								
							@@ -1,47 +1,72 @@
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
  description = "xeals's flake";
 | 
					  description = "xeals's Nix repository";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  inputs = {
 | 
					  inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
 | 
				
			||||||
    nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
 | 
					  inputs.flake-utils.url = "github:numtide/flake-utils";
 | 
				
			||||||
    flake-utils.url = "github:numtide/flake-utils";
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  outputs = { self, nixpkgs, flake-utils }:
 | 
					  outputs = { self, nixpkgs, flake-utils }:
 | 
				
			||||||
    let
 | 
					    let
 | 
				
			||||||
      inherit (flake-utils.lib) eachDefaultSystem flattenTree;
 | 
					      inherit (nixpkgs) lib;
 | 
				
			||||||
      inherit (nixpkgs.lib.attrsets) filterAttrs mapAttrs;
 | 
					      inherit (flake-utils.lib) mkApp;
 | 
				
			||||||
    in
 | 
					    in
 | 
				
			||||||
    {
 | 
					    flake-utils.lib.eachDefaultSystem
 | 
				
			||||||
      nixosModules = mapAttrs (_: path: import path) (import ./modules);
 | 
					      (system:
 | 
				
			||||||
 | 
					        let
 | 
				
			||||||
 | 
					          pkgs = import nixpkgs { inherit system; };
 | 
				
			||||||
 | 
					        in
 | 
				
			||||||
 | 
					        {
 | 
				
			||||||
 | 
					          packages = import ./pkgs/top-level { localSystem = system; inherit pkgs; };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          checks = {
 | 
				
			||||||
 | 
					            nixpkgs-fmt = pkgs.writeShellScriptBin "nixpkgs-fmt-check" ''
 | 
				
			||||||
 | 
					              ${pkgs.nixpkgs-fmt}/bin/nixpkgs-fmt --check .
 | 
				
			||||||
 | 
					            '';
 | 
				
			||||||
 | 
					            deadnix = pkgs.writeShellScriptBin "deadnix-check" ''
 | 
				
			||||||
 | 
					              ${pkgs.deadnix}/bin/deadnix --fail .
 | 
				
			||||||
 | 
					            '';
 | 
				
			||||||
 | 
					            # Ensures that the NUR bot can evaluate and find all our packages.
 | 
				
			||||||
 | 
					            # Normally we'd also run with `--option restrict-eval true`, but
 | 
				
			||||||
 | 
					            # this is incompatible with flakes because reasons.
 | 
				
			||||||
 | 
					            nur = pkgs.writeShellScriptBin "nur-check" ''
 | 
				
			||||||
 | 
					              # Prefer nixpkgs channel (actual build), otherwise read from flake.lock (CI)
 | 
				
			||||||
 | 
					              if ! nixpkgs=$(nix-instantiate --find-file nixpkgs 2>/dev/null); then
 | 
				
			||||||
 | 
					                _rev=$(${pkgs.jq}/bin/jq -r .nodes.nixpkgs.locked.rev flake.lock)
 | 
				
			||||||
 | 
					                nixpkgs="https://github.com/nixos/nixpkgs/archive/''${_rev}.tar.gz"
 | 
				
			||||||
 | 
					              fi
 | 
				
			||||||
 | 
					              nix-env -f . -qa \* --meta \
 | 
				
			||||||
 | 
					                --allowed-uris https://static.rust-lang.org \
 | 
				
			||||||
 | 
					                --option allow-import-from-derivation true \
 | 
				
			||||||
 | 
					                --drv-path --show-trace \
 | 
				
			||||||
 | 
					                -I nixpkgs="$nixpkgs" \
 | 
				
			||||||
 | 
					                -I ./ \
 | 
				
			||||||
 | 
					                --json | ${pkgs.jq}/bin/jq -r 'values | .[].name'
 | 
				
			||||||
 | 
					            '';
 | 
				
			||||||
 | 
					          };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          devShells.ci = pkgs.mkShellNoCC {
 | 
				
			||||||
 | 
					            buildInputs = [ pkgs.nix-build-uncached ];
 | 
				
			||||||
 | 
					          };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					          apps = {
 | 
				
			||||||
 | 
					            alacritty = mkApp { drv = pkgs.alacritty-ligatures; exePath = "/bin/alacritty"; };
 | 
				
			||||||
 | 
					            protonmail-bridge = mkApp { drv = pkgs.protonmail-bridge; };
 | 
				
			||||||
 | 
					            protonmail-bridge-headless = mkApp { drv = pkgs.protonmail-bridge; };
 | 
				
			||||||
 | 
					            psst-cli = mkApp { drv = pkgs.psst; exePath = "/bin/psst-cli"; };
 | 
				
			||||||
 | 
					            psst-gui = mkApp { drv = pkgs.psst; exePath = "/bin/psst-gui"; };
 | 
				
			||||||
 | 
					            samrewritten = mkApp { drv = pkgs.samrewritten; };
 | 
				
			||||||
 | 
					            spotify-ripper = mkApp { drv = pkgs.spotify-ripper; };
 | 
				
			||||||
 | 
					          };
 | 
				
			||||||
 | 
					        })
 | 
				
			||||||
 | 
					    // {
 | 
				
			||||||
 | 
					      nixosModules = lib.mapAttrs (_: path: import path) (import ./modules) // {
 | 
				
			||||||
 | 
					        default = {
 | 
				
			||||||
 | 
					          imports = lib.attrValues self.nixosModules;
 | 
				
			||||||
 | 
					        };
 | 
				
			||||||
 | 
					      };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      overlays = import ./overlays // {
 | 
					      overlays = import ./overlays // {
 | 
				
			||||||
        pkgs = final: prev: import ./pkgs/top-level/all-packages.nix { pkgs = prev; };
 | 
					        pkgs = _: prev: import ./pkgs/top-level/all-packages.nix { pkgs = prev; };
 | 
				
			||||||
 | 
					        default = _: _: { xeals = nixpkgs.lib.composeExtensions self.overlays.pkgs; };
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
      overlay = final: prev: {
 | 
					 | 
				
			||||||
        xeals = nixpkgs.lib.composeExtensions self.overlays.pkgs;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    } // eachDefaultSystem (system:
 | 
					 | 
				
			||||||
      let
 | 
					 | 
				
			||||||
        pkgs = nixpkgs.legacyPackages.${system};
 | 
					 | 
				
			||||||
        xPkgs = import ./pkgs/top-level/all-packages.nix { inherit pkgs; };
 | 
					 | 
				
			||||||
        mkApp = opts: { type = "app"; } // opts;
 | 
					 | 
				
			||||||
      in
 | 
					 | 
				
			||||||
      rec {
 | 
					 | 
				
			||||||
        packages = filterAttrs
 | 
					 | 
				
			||||||
          (attr: drv: builtins.elem system (drv.meta.platforms or [ ]))
 | 
					 | 
				
			||||||
          (flattenTree xPkgs);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
        apps = flattenTree {
 | 
					 | 
				
			||||||
          alacritty = mkApp { program = "${packages.alacritty-ligatures}/bin/alacritty"; };
 | 
					 | 
				
			||||||
          protonmail-bridge = mkApp { program = "${packages.protonmail-bridge}/bin/protonmail-bridge"; };
 | 
					 | 
				
			||||||
          protonmail-bridge-headless = mkApp { program = "${packages.protonmail-bridge}/bin/protonmail-bridge"; };
 | 
					 | 
				
			||||||
          psst = {
 | 
					 | 
				
			||||||
            cli = mkApp { program = "${packages.psst}/bin/psst-cli"; };
 | 
					 | 
				
			||||||
            gui = mkApp { program = "${packages.psst}/bin/psst-gui"; };
 | 
					 | 
				
			||||||
          };
 | 
					 | 
				
			||||||
          samrewritten = mkApp { program = "${packages.samrewritten}/bin/samrewritten"; };
 | 
					 | 
				
			||||||
          spotify-ripper = mkApp { program = "${packages.spotify-ripper}/bin/spotify-ripper"; };
 | 
					 | 
				
			||||||
        };
 | 
					 | 
				
			||||||
      });
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -2,6 +2,7 @@
 | 
				
			|||||||
  amdgpu-common = ./services/hardware/amdgpu-common.nix;
 | 
					  amdgpu-common = ./services/hardware/amdgpu-common.nix;
 | 
				
			||||||
  amdgpu-fan = ./services/hardware/amdgpu-fan.nix;
 | 
					  amdgpu-fan = ./services/hardware/amdgpu-fan.nix;
 | 
				
			||||||
  amdgpu-pwm = ./services/hardware/amdgpu-pwm.nix;
 | 
					  amdgpu-pwm = ./services/hardware/amdgpu-pwm.nix;
 | 
				
			||||||
 | 
					  dunst = ./services/x11/dunst.nix;
 | 
				
			||||||
  radeon-profile-daemon = ./services/hardware/radeon-profile-daemon.nix;
 | 
					  radeon-profile-daemon = ./services/hardware/radeon-profile-daemon.nix;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ config, lib, pkgs, ... }:
 | 
					{ lib, ... }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
with lib;
 | 
					with lib;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -7,7 +7,7 @@ with lib;
 | 
				
			|||||||
    cards = mkOption {
 | 
					    cards = mkOption {
 | 
				
			||||||
      type = types.listOf types.str;
 | 
					      type = types.listOf types.str;
 | 
				
			||||||
      default = [ "card0" ];
 | 
					      default = [ "card0" ];
 | 
				
			||||||
      example = literalExample ''[ "card0" ]'';
 | 
					      example = [ "card0" "card1" ];
 | 
				
			||||||
      description = ''
 | 
					      description = ''
 | 
				
			||||||
        A list of cards to enable fan configuration for. The identifiers for
 | 
					        A list of cards to enable fan configuration for. The identifiers for
 | 
				
			||||||
        each device can be found in /sys/class/drm/ as card0, card1, etc.
 | 
					        each device can be found in /sys/class/drm/ as card0, card1, etc.
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -33,14 +33,12 @@ in
 | 
				
			|||||||
        [ 75 89 ]
 | 
					        [ 75 89 ]
 | 
				
			||||||
        [ 80 100 ]
 | 
					        [ 80 100 ]
 | 
				
			||||||
      ];
 | 
					      ];
 | 
				
			||||||
      example = literalExample ''
 | 
					      example = [
 | 
				
			||||||
        [
 | 
					        [ 0 0 ]
 | 
				
			||||||
          [ 0 0 ]
 | 
					        [ 40 30 ]
 | 
				
			||||||
          [ 40 30 ]
 | 
					        [ 60 50 ]
 | 
				
			||||||
          [ 60 50 ]
 | 
					        [ 80 100 ]
 | 
				
			||||||
          [ 80 100 ]
 | 
					      ];
 | 
				
			||||||
        ]
 | 
					 | 
				
			||||||
      '';
 | 
					 | 
				
			||||||
      description = ''
 | 
					      description = ''
 | 
				
			||||||
        A list of temperature-fan speed pairs. The temperature is specified in
 | 
					        A list of temperature-fan speed pairs. The temperature is specified in
 | 
				
			||||||
        degrees celcius, and speed is specified in %.
 | 
					        degrees celcius, and speed is specified in %.
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ config, lib, pkgs, ... }:
 | 
					{ config, lib, ... }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
with lib;
 | 
					with lib;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										68
									
								
								modules/services/x11/dunst.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										68
									
								
								modules/services/x11/dunst.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,68 @@
 | 
				
			|||||||
 | 
					{ config, lib, pkgs, ... }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					with lib;
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					  cfg = config.services.dunst;
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					  options.services.dunst = {
 | 
				
			||||||
 | 
					    enable = mkEnableOption "dunst";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    package = mkOption {
 | 
				
			||||||
 | 
					      type = types.package;
 | 
				
			||||||
 | 
					      default = pkgs.dunst;
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    settings = mkOption {
 | 
				
			||||||
 | 
					      type = types.nullOr types.attrs;
 | 
				
			||||||
 | 
					      default = null;
 | 
				
			||||||
 | 
					      description = ''
 | 
				
			||||||
 | 
					        Configuration set alternative to <literal>configFile</literal>.
 | 
				
			||||||
 | 
					      '';
 | 
				
			||||||
 | 
					      example = {
 | 
				
			||||||
 | 
					        global = {
 | 
				
			||||||
 | 
					          monitor = 0;
 | 
				
			||||||
 | 
					          follow = "none";
 | 
				
			||||||
 | 
					        };
 | 
				
			||||||
 | 
					      };
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    configFile = mkOption {
 | 
				
			||||||
 | 
					      type = types.nullOr types.path;
 | 
				
			||||||
 | 
					      default = null;
 | 
				
			||||||
 | 
					      description = "Path to dunstrc configuration file.";
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  config = mkIf cfg.enable {
 | 
				
			||||||
 | 
					    assertions = [
 | 
				
			||||||
 | 
					      {
 | 
				
			||||||
 | 
					        assertion = !(cfg.settings != null && cfg.configFile != null);
 | 
				
			||||||
 | 
					        message = "only one of services.dunst.settings or .configFile may be specified";
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    environment.systemPackages = [ (getOutput "man" cfg.package) ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    systemd.user.services.dunst = {
 | 
				
			||||||
 | 
					      description = "Dunst notification daemon";
 | 
				
			||||||
 | 
					      documentation = [ "man:dunst(1)" ];
 | 
				
			||||||
 | 
					      after = [ "graphical-session-pre.target" ];
 | 
				
			||||||
 | 
					      partOf = [ "graphical-session.target" ];
 | 
				
			||||||
 | 
					      serviceConfig = {
 | 
				
			||||||
 | 
					        Type = "dbus";
 | 
				
			||||||
 | 
					        BusName = "org.freedesktop.Notifications";
 | 
				
			||||||
 | 
					        ExecStart =
 | 
				
			||||||
 | 
					          let
 | 
				
			||||||
 | 
					            config =
 | 
				
			||||||
 | 
					              if (cfg.settings != null)
 | 
				
			||||||
 | 
					              then pkgs.writeText "dunstrc" (generators.toINI { } cfg.settings)
 | 
				
			||||||
 | 
					              else if (cfg.configFile != null)
 | 
				
			||||||
 | 
					              then cfg.configFile
 | 
				
			||||||
 | 
					              else null;
 | 
				
			||||||
 | 
					          in
 | 
				
			||||||
 | 
					          "${cfg.package}/bin/dunst ${optionalString (config != null) "-conf ${config}"}";
 | 
				
			||||||
 | 
					      };
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@@ -2,7 +2,7 @@
 | 
				
			|||||||
# case where you don't want to add the whole NUR namespace to your
 | 
					# case where you don't want to add the whole NUR namespace to your
 | 
				
			||||||
# configuration.
 | 
					# configuration.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
self: super:
 | 
					_self: super:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
let
 | 
					let
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, python3Packages
 | 
					, python3Packages
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -20,7 +20,7 @@ python3Packages.buildPythonApplication rec {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  doCheck = false;
 | 
					  doCheck = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    homepage = "https://github.com/Prior99/mopidy-subidy";
 | 
					    homepage = "https://github.com/Prior99/mopidy-subidy";
 | 
				
			||||||
    description = "Mopidy extension for playing music from Subsonic servers";
 | 
					    description = "Mopidy extension for playing music from Subsonic servers";
 | 
				
			||||||
    license = licenses.bsd3;
 | 
					    license = licenses.bsd3;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -21,21 +21,25 @@ let
 | 
				
			|||||||
    ];
 | 
					    ];
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  generateCommon = lib.makeOverridable ({
 | 
					  generateCommon = lib.makeOverridable (
 | 
				
			||||||
    common ? ./manual-common-packages.nix
 | 
					    { common ? ./manual-common-packages.nix
 | 
				
			||||||
  }: let
 | 
					    }:
 | 
				
			||||||
 | 
					    let
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    imported = import common {
 | 
					      imported = import common {
 | 
				
			||||||
      inherit (self) callPackage;
 | 
					        inherit (self) callPackage;
 | 
				
			||||||
    };
 | 
					      };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    super = imported;
 | 
					      super = imported;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    overrides = { };
 | 
					      overrides = { };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    jetbrainsPlugins = super // overrides;
 | 
					      jetbrainsPlugins = super // overrides;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  in jetbrainsPlugins // { inherit commonBuild; });
 | 
					    in
 | 
				
			||||||
 | 
					    jetbrainsPlugins // { inherit commonBuild; }
 | 
				
			||||||
 | 
					  );
 | 
				
			||||||
 | 
					
 | 
				
			||||||
in generateCommon { }
 | 
					in
 | 
				
			||||||
 | 
					generateCommon { }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -9,21 +9,25 @@ let
 | 
				
			|||||||
    jetbrainsPlatforms = [ "idea-community" "idea-ultimate" ];
 | 
					    jetbrainsPlatforms = [ "idea-community" "idea-ultimate" ];
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  generateIdea = lib.makeOverridable ({
 | 
					  generateIdea = lib.makeOverridable (
 | 
				
			||||||
    idea ? ./manual-idea-packages.nix
 | 
					    { idea ? ./manual-idea-packages.nix
 | 
				
			||||||
  }: let
 | 
					    }:
 | 
				
			||||||
 | 
					    let
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    imported = import idea {
 | 
					      imported = import idea {
 | 
				
			||||||
      inherit (self) callPackage;
 | 
					        inherit (self) callPackage;
 | 
				
			||||||
    };
 | 
					      };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    super = imported;
 | 
					      super = imported;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    overrides = { };
 | 
					      overrides = { };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    ideaPlugins = super // overrides;
 | 
					      ideaPlugins = super // overrides;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  in ideaPlugins // { inherit ideaBuild; });
 | 
					    in
 | 
				
			||||||
 | 
					    ideaPlugins // { inherit ideaBuild; }
 | 
				
			||||||
 | 
					  );
 | 
				
			||||||
 | 
					
 | 
				
			||||||
in generateIdea { }
 | 
					in
 | 
				
			||||||
 | 
					generateIdea { }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -2,12 +2,10 @@ diff --git a/include/components/types.hpp b/include/components/types.hpp
 | 
				
			|||||||
index 8125d4b..c435f4a 100644
 | 
					index 8125d4b..c435f4a 100644
 | 
				
			||||||
--- a/include/components/types.hpp
 | 
					--- a/include/components/types.hpp
 | 
				
			||||||
+++ b/include/components/types.hpp
 | 
					+++ b/include/components/types.hpp
 | 
				
			||||||
@@ -57,7 +57,7 @@ enum class controltag {
 | 
					@@ -43,5 +43,6 @@ enum class controltag {
 | 
				
			||||||
   R,  // Reset all open tags (B, F, T, o, u). Used at module edges
 | 
					   DOUBLE_MIDDLE,
 | 
				
			||||||
 | 
					   DOUBLE_RIGHT,
 | 
				
			||||||
 | 
					+  EXTRA,
 | 
				
			||||||
 | 
					   // Terminator value, do not use
 | 
				
			||||||
 | 
					   BTN_COUNT,
 | 
				
			||||||
 };
 | 
					 };
 | 
				
			||||||
 | 
					 | 
				
			||||||
-enum class mousebtn { NONE = 0, LEFT, MIDDLE, RIGHT, SCROLL_UP, SCROLL_DOWN, DOUBLE_LEFT, DOUBLE_MIDDLE, DOUBLE_RIGHT };
 | 
					 | 
				
			||||||
+enum class mousebtn { NONE = 0, LEFT, MIDDLE, RIGHT, SCROLL_UP, SCROLL_DOWN, DOUBLE_LEFT, DOUBLE_MIDDLE, DOUBLE_RIGHT, EXTRA };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 enum class strut {
 | 
					 | 
				
			||||||
   LEFT = 0,
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										48
									
								
								pkgs/applications/networking/protonmail-bridge/common.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										48
									
								
								pkgs/applications/networking/protonmail-bridge/common.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,48 @@
 | 
				
			|||||||
 | 
					{ lib
 | 
				
			||||||
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					, buildGoModule
 | 
				
			||||||
 | 
					, pkg-config
 | 
				
			||||||
 | 
					, libsecret
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{ pname
 | 
				
			||||||
 | 
					, tags
 | 
				
			||||||
 | 
					, ...
 | 
				
			||||||
 | 
					}@args:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					buildGoModule (lib.recursiveUpdate args rec {
 | 
				
			||||||
 | 
					  inherit pname;
 | 
				
			||||||
 | 
					  version = "1.8.10";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  src = fetchFromGitHub {
 | 
				
			||||||
 | 
					    owner = "ProtonMail";
 | 
				
			||||||
 | 
					    repo = "proton-bridge";
 | 
				
			||||||
 | 
					    rev = "br-${version}";
 | 
				
			||||||
 | 
					    sha256 = "1na8min9cmn82lpad58abw6837k303fr09l6cvzswaxs73f231ig";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  vendorSha256 = "1219xa1347877bfhnid15y6w9s4hf1czbrmll2iha4gpsmg066bb";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  nativeBuildInputs = (args.nativeBuildInputs or [ ]) ++ [
 | 
				
			||||||
 | 
					    pkg-config
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  buildInputs = (args.buildInputs or [ ]) ++ [
 | 
				
			||||||
 | 
					    libsecret
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  inherit tags;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ldflags = [
 | 
				
			||||||
 | 
					    "-X github.com/ProtonMail/proton-bridge/pkg/constants.Version=${version}"
 | 
				
			||||||
 | 
					    "-X github.com/ProtonMail/proton-bridge/pkg/constants.Revision=${version}"
 | 
				
			||||||
 | 
					    "-X github.com/ProtonMail/proton-bridge/pkg/constants.BuildDate=unknown"
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = with lib; {
 | 
				
			||||||
 | 
					    description = "Integrate ProtonMail paid account with any program that supports IMAP and SMTP";
 | 
				
			||||||
 | 
					    homepage = "https://protonmail.com";
 | 
				
			||||||
 | 
					    license = licenses.gpl3;
 | 
				
			||||||
 | 
					    plaforms = platforms.x86_64;
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					})
 | 
				
			||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, buildGoModule
 | 
					, buildGoModule
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -7,62 +7,12 @@
 | 
				
			|||||||
, libsecret
 | 
					, libsecret
 | 
				
			||||||
, pkg-config
 | 
					, pkg-config
 | 
				
			||||||
, qtbase
 | 
					, qtbase
 | 
				
			||||||
, qtdoc
 | 
					 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					 | 
				
			||||||
let
 | 
					let
 | 
				
			||||||
 | 
					  builder = import ./common.nix {
 | 
				
			||||||
  builder =
 | 
					    inherit lib fetchFromGitHub buildGoModule libsecret pkg-config;
 | 
				
			||||||
    { pname
 | 
					  };
 | 
				
			||||||
    , tags
 | 
					 | 
				
			||||||
    , ...
 | 
					 | 
				
			||||||
    }@args:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    buildGoModule (stdenv.lib.recursiveUpdate args rec {
 | 
					 | 
				
			||||||
      inherit pname;
 | 
					 | 
				
			||||||
      version = "1.5.6";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      src = fetchFromGitHub {
 | 
					 | 
				
			||||||
        owner = "ProtonMail";
 | 
					 | 
				
			||||||
        repo = "proton-bridge";
 | 
					 | 
				
			||||||
        rev = "br-${version}";
 | 
					 | 
				
			||||||
        sha256 = "1na8min9cmn82lpad58abw6837k303fr09l6cvzswaxs73f231ig";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      vendorSha256 = "1219xa1347877bfhnid15y6w9s4hf1czbrmll2iha4gpsmg066bb";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      nativeBuildInputs = (args.nativeBuildInputs or [ ]) ++ [
 | 
					 | 
				
			||||||
        pkg-config
 | 
					 | 
				
			||||||
      ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      buildInputs = (args.buildInputs or [ ]) ++ [
 | 
					 | 
				
			||||||
        libsecret
 | 
					 | 
				
			||||||
      ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      buildFlagsArray =
 | 
					 | 
				
			||||||
        let
 | 
					 | 
				
			||||||
          t = "github.com/ProtonMail/proton-bridge/pkg/constants";
 | 
					 | 
				
			||||||
        in
 | 
					 | 
				
			||||||
        [
 | 
					 | 
				
			||||||
          "-tags=${tags}"
 | 
					 | 
				
			||||||
          ''
 | 
					 | 
				
			||||||
            -ldflags=
 | 
					 | 
				
			||||||
              -X ${t}.Version=${version}
 | 
					 | 
				
			||||||
              -X ${t}.Revision=unknown
 | 
					 | 
				
			||||||
              -X ${t}.BuildDate=unknown
 | 
					 | 
				
			||||||
          ''
 | 
					 | 
				
			||||||
        ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      meta = with stdenv.lib; {
 | 
					 | 
				
			||||||
        description = "Integrate ProtonMail paid account with any program that supports IMAP and SMTP";
 | 
					 | 
				
			||||||
        homepage = "https://protonmail.com";
 | 
					 | 
				
			||||||
        license = licenses.gpl3;
 | 
					 | 
				
			||||||
        plaforms = platforms.x86_64;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    });
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
in
 | 
					in
 | 
				
			||||||
 | 
					 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  protonmail-bridge = builder (import ./app.nix { inherit qtbase go goModules; });
 | 
					  protonmail-bridge = builder (import ./app.nix { inherit qtbase go goModules; });
 | 
				
			||||||
  protonmail-bridge-headless = builder (import ./headless.nix { });
 | 
					  protonmail-bridge-headless = builder (import ./headless.nix { });
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,30 +1,17 @@
 | 
				
			|||||||
{}:
 | 
					{}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
rec {
 | 
					{
 | 
				
			||||||
  pname = "protonmail-bridge-headless";
 | 
					  pname = "protonmail-bridge-headless";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  tags = "pmapi_prod nogui";
 | 
					  tags = [ "pmapi_prod" "nogui" ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # FIXME: There's something fucky going on in the buildFlagsArray
 | 
					  # REVIEW: Some issue with IMAP tests that probably fail due to network
 | 
				
			||||||
  # substitution. I shouldn't need to do this.
 | 
					  # sandboxing.
 | 
				
			||||||
  buildPhase =
 | 
					  doCheck = false;
 | 
				
			||||||
    let
 | 
					 | 
				
			||||||
      t = "github.com/ProtonMail/proton-bridge/pkg/constants";
 | 
					 | 
				
			||||||
    in
 | 
					 | 
				
			||||||
    ''
 | 
					 | 
				
			||||||
      runHook preBuild
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      go install \
 | 
					 | 
				
			||||||
        -tags="${tags}" \
 | 
					 | 
				
			||||||
        -ldflags="-X ${t}.Version=1.3.2 -X ${t}.Revision=unknown -X ${t}.BuildDate=unknown" \
 | 
					 | 
				
			||||||
        cmd/Desktop-Bridge/main.go
 | 
					 | 
				
			||||||
      mv $GOPATH/bin/main $GOPATH/bin/Desktop-Bridge
 | 
					 | 
				
			||||||
        
 | 
					 | 
				
			||||||
      runHook postBuild
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # Fix up name.
 | 
					  # Fix up name.
 | 
				
			||||||
  postInstall = ''
 | 
					  postInstall = ''
 | 
				
			||||||
    mv $out/bin/Desktop-Bridge $out/bin/protonmail-bridge
 | 
					    mv $out/bin/Desktop-Bridge $out/bin/protonmail-bridge
 | 
				
			||||||
 | 
					    mv $out/bin/Import-Export $out/bin/protonmail-import-export
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										55
									
								
								pkgs/by-name/al/alacritty-ligatures/package.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										55
									
								
								pkgs/by-name/al/alacritty-ligatures/package.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,55 @@
 | 
				
			|||||||
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					, alacritty
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					, fontconfig
 | 
				
			||||||
 | 
					, freetype
 | 
				
			||||||
 | 
					, libglvnd
 | 
				
			||||||
 | 
					, libxcb
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					alacritty.overrideAttrs (oldAttrs: rec {
 | 
				
			||||||
 | 
					  pname = "${oldAttrs.pname}-ligatures";
 | 
				
			||||||
 | 
					  version = "0.7.2.20210209.g3ed0430";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  src = fetchFromGitHub {
 | 
				
			||||||
 | 
					    owner = "zenixls2";
 | 
				
			||||||
 | 
					    repo = "alacritty";
 | 
				
			||||||
 | 
					    fetchSubmodules = true;
 | 
				
			||||||
 | 
					    rev = "3ed043046fc74f288d4c8fa7e4463dc201213500";
 | 
				
			||||||
 | 
					    sha256 = "1dGk4ORzMSUQhuKSt5Yo7rOJCJ5/folwPX2tLiu0suA=";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  cargoDeps = oldAttrs.cargoDeps.overrideAttrs (lib.const {
 | 
				
			||||||
 | 
					    name = "${pname}-${version}-vendor.tar.gz";
 | 
				
			||||||
 | 
					    inherit src;
 | 
				
			||||||
 | 
					    outputSha256 = "pONu6caJmEKnbr7j+o9AyrYNpS4Q8OEjNZOhGTalncc=";
 | 
				
			||||||
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ligatureInputs = [
 | 
				
			||||||
 | 
					    fontconfig
 | 
				
			||||||
 | 
					    freetype
 | 
				
			||||||
 | 
					    libglvnd
 | 
				
			||||||
 | 
					    stdenv.cc.cc.lib
 | 
				
			||||||
 | 
					    libxcb
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  preferLocalBuild = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  buildInputs = (oldAttrs.buildInputs or [ ]) ++ ligatureInputs;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # HACK: One of the ligature libraries required the C++ stdlib at runtime,
 | 
				
			||||||
 | 
					  # and I can't work out a better way to push it to the RPATH.
 | 
				
			||||||
 | 
					  postInstall = lib.optional (!stdenv.isDarwin) ''
 | 
				
			||||||
 | 
					    patchelf \
 | 
				
			||||||
 | 
					      --set-rpath ${lib.makeLibraryPath ligatureInputs}:"$(patchelf --print-rpath $out/bin/alacritty)" \
 | 
				
			||||||
 | 
					      $out/bin/alacritty
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = oldAttrs.meta // {
 | 
				
			||||||
 | 
					    description = "Alacritty with ligature patch applied";
 | 
				
			||||||
 | 
					    homepage = "https://github.com/zenixls2/alacritty/tree/ligature";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					})
 | 
				
			||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, python3Packages
 | 
					, python3Packages
 | 
				
			||||||
@@ -20,7 +20,12 @@ python3Packages.buildPythonApplication rec {
 | 
				
			|||||||
    pyyaml
 | 
					    pyyaml
 | 
				
			||||||
  ];
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  patchPhase = ''
 | 
				
			||||||
 | 
					    substituteInPlace setup.py \
 | 
				
			||||||
 | 
					      --replace PROJECTVERSION "${version}"
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "Fan controller for AMD graphics cards running the amdgpu driver on Linux";
 | 
					    description = "Fan controller for AMD graphics cards running the amdgpu driver on Linux";
 | 
				
			||||||
    homepage = "https://github.com/chestm007/amdgpu-fan";
 | 
					    homepage = "https://github.com/chestm007/amdgpu-fan";
 | 
				
			||||||
    license = licenses.gpl2;
 | 
					    license = licenses.gpl2;
 | 
				
			||||||
							
								
								
									
										46
									
								
								pkgs/by-name/at/atlauncher/package.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										46
									
								
								pkgs/by-name/at/atlauncher/package.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,46 @@
 | 
				
			|||||||
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
 | 
					, fetchurl
 | 
				
			||||||
 | 
					, makeWrapper
 | 
				
			||||||
 | 
					, jdk17
 | 
				
			||||||
 | 
					, udev
 | 
				
			||||||
 | 
					, xorg
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					stdenv.mkDerivation rec {
 | 
				
			||||||
 | 
					  pname = "atlauncher";
 | 
				
			||||||
 | 
					  version = "3.4.33.1";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  src = fetchurl {
 | 
				
			||||||
 | 
					    url = "https://github.com/ATLauncher/ATLauncher/releases/download/v${version}/ATLauncher-${version}.jar";
 | 
				
			||||||
 | 
					    hash = "sha256-YfTo3Vp4ACQPQJWCujpAv8J0i2FuG5MLaIjNdBPN1Ns=";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  dontUnpack = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  nativeBuildInputs = [ makeWrapper ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  installPhase = ''
 | 
				
			||||||
 | 
					    mkdir -p $out/bin $out/share/java
 | 
				
			||||||
 | 
					    cp $src $out/share/java/ATLauncher.jar
 | 
				
			||||||
 | 
					    makeWrapper ${jdk17}/bin/java $out/bin/atlauncher \
 | 
				
			||||||
 | 
					      --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ xorg.libXxf86vm udev ]}" \
 | 
				
			||||||
 | 
					      --add-flags "-jar $out/share/java/ATLauncher.jar" \
 | 
				
			||||||
 | 
					      --add-flags "--working-dir \''${XDG_DATA_HOME:-\$HOME/.local/share}/ATLauncher" \
 | 
				
			||||||
 | 
					      --add-flags "--no-launcher-update"
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = {
 | 
				
			||||||
 | 
					    description = "Minecraft launcher";
 | 
				
			||||||
 | 
					    longDescription = ''
 | 
				
			||||||
 | 
					      ATLauncher is a Launcher for Minecraft which integrates multiple different
 | 
				
			||||||
 | 
					      ModPacks to allow you to download and install ModPacks easily and quickly.
 | 
				
			||||||
 | 
					    '';
 | 
				
			||||||
 | 
					    sourceProvenance = [
 | 
				
			||||||
 | 
					      (lib.sourceTypes.binaryBytecode or { shortName = "binaryBytecode"; isSource = false; })
 | 
				
			||||||
 | 
					    ];
 | 
				
			||||||
 | 
					    license = lib.licenses.gpl3Only;
 | 
				
			||||||
 | 
					    platforms = lib.platforms.all;
 | 
				
			||||||
 | 
					    homepage = "https://atlauncher.com/";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@@ -1,15 +1,12 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitLab
 | 
					, fetchFromGitLab
 | 
				
			||||||
, fetchzip
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
, cereal
 | 
					, cereal
 | 
				
			||||||
, cmake
 | 
					, cmake
 | 
				
			||||||
, git
 | 
					 | 
				
			||||||
, libGL
 | 
					, libGL
 | 
				
			||||||
, libX11
 | 
					, libX11
 | 
				
			||||||
, libinput
 | 
					, libinput
 | 
				
			||||||
, libxkbcommon
 | 
					, libxkbcommon
 | 
				
			||||||
, mesa
 | 
					 | 
				
			||||||
, meson
 | 
					, meson
 | 
				
			||||||
, ninja
 | 
					, ninja
 | 
				
			||||||
, pixman
 | 
					, pixman
 | 
				
			||||||
@@ -18,7 +15,6 @@
 | 
				
			|||||||
, wayland
 | 
					, wayland
 | 
				
			||||||
, wayland-protocols
 | 
					, wayland-protocols
 | 
				
			||||||
, wlroots
 | 
					, wlroots
 | 
				
			||||||
, xwayland
 | 
					 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
stdenv.mkDerivation rec {
 | 
					stdenv.mkDerivation rec {
 | 
				
			||||||
@@ -62,10 +58,11 @@ stdenv.mkDerivation rec {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  passthru.providedSessions = [ "cardboard" ];
 | 
					  passthru.providedSessions = [ "cardboard" ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "Scrollable tiling Wayland compositor designed with laptops in mind";
 | 
					    description = "Scrollable tiling Wayland compositor designed with laptops in mind";
 | 
				
			||||||
    homepage = "https://gitlab.com/cardboardwm/cardboard";
 | 
					    homepage = "https://gitlab.com/cardboardwm/cardboard";
 | 
				
			||||||
    license = stdenv.lib.licenses.gpl3;
 | 
					    license = licenses.gpl3;
 | 
				
			||||||
    platforms = wlroots.meta.platforms;
 | 
					    platforms = wlroots.meta.platforms;
 | 
				
			||||||
 | 
					    broken = true;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
							
								
								
									
										94
									
								
								pkgs/by-name/cu/cura5/package.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										94
									
								
								pkgs/by-name/cu/cura5/package.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,94 @@
 | 
				
			|||||||
 | 
					{ lib
 | 
				
			||||||
 | 
					, stdenv
 | 
				
			||||||
 | 
					, fetchurl
 | 
				
			||||||
 | 
					, writeScriptBin
 | 
				
			||||||
 | 
					, appimageTools
 | 
				
			||||||
 | 
					, copyDesktopItems
 | 
				
			||||||
 | 
					, makeDesktopItem
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					  pname = "cura5";
 | 
				
			||||||
 | 
					  version = "5.4.0";
 | 
				
			||||||
 | 
					  name = "${pname}-${version}";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  cura5 = appimageTools.wrapType2 {
 | 
				
			||||||
 | 
					    inherit pname version;
 | 
				
			||||||
 | 
					    src = fetchurl {
 | 
				
			||||||
 | 
					      url = "https://github.com/Ultimaker/Cura/releases/download/${version}/Ultimaker-Cura-${version}-linux-modern.AppImage";
 | 
				
			||||||
 | 
					      hash = "sha256-QVv7Wkfo082PH6n6rpsB79st2xK2+Np9ivBg/PYZd74=";
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					    extraPkgs = _: [ ];
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					  script = writeScriptBin pname ''
 | 
				
			||||||
 | 
					    #!${stdenv.shell}
 | 
				
			||||||
 | 
					    # AppImage version of Cura loses current working directory and treats all paths relateive to $HOME.
 | 
				
			||||||
 | 
					    # So we convert each of the files passed as argument to an absolute path.
 | 
				
			||||||
 | 
					    # This fixes use cases like `cd /path/to/my/files; cura mymodel.stl anothermodel.stl`.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    args=()
 | 
				
			||||||
 | 
					    for a in "$@"; do
 | 
				
			||||||
 | 
					      if [ -e "$a" ]; then
 | 
				
			||||||
 | 
					        a="$(realpath "$a")"
 | 
				
			||||||
 | 
					      fi
 | 
				
			||||||
 | 
					      args+=("$a")
 | 
				
			||||||
 | 
					    done
 | 
				
			||||||
 | 
					    exec "${cura5}/bin/${name}" "''${args[@]}"
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					stdenv.mkDerivation rec {
 | 
				
			||||||
 | 
					  inherit pname version;
 | 
				
			||||||
 | 
					  dontUnpack = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  nativeBuildInputs = [ copyDesktopItems ];
 | 
				
			||||||
 | 
					  desktopItems = [
 | 
				
			||||||
 | 
					    # Based on upstream.
 | 
				
			||||||
 | 
					    # https://github.com/Ultimaker/Cura/blob/main/packaging/AppImage/cura.desktop.jinja
 | 
				
			||||||
 | 
					    (makeDesktopItem {
 | 
				
			||||||
 | 
					      name = "cura";
 | 
				
			||||||
 | 
					      desktopName = "UltiMaker Cura";
 | 
				
			||||||
 | 
					      genericName = "3D Printing Software";
 | 
				
			||||||
 | 
					      comment = meta.longDescription;
 | 
				
			||||||
 | 
					      exec = "cura5";
 | 
				
			||||||
 | 
					      icon = "cura-icon";
 | 
				
			||||||
 | 
					      terminal = false;
 | 
				
			||||||
 | 
					      type = "Application";
 | 
				
			||||||
 | 
					      mimeTypes = [
 | 
				
			||||||
 | 
					        "model/stl"
 | 
				
			||||||
 | 
					        "application/vnd.ms-3mfdocument"
 | 
				
			||||||
 | 
					        "application/prs.wavefront-obj"
 | 
				
			||||||
 | 
					        "image/bmp"
 | 
				
			||||||
 | 
					        "image/gif"
 | 
				
			||||||
 | 
					        "image/jpeg"
 | 
				
			||||||
 | 
					        "image/png"
 | 
				
			||||||
 | 
					        "text/x-gcode"
 | 
				
			||||||
 | 
					        "application/x-amf"
 | 
				
			||||||
 | 
					        "application/x-ply"
 | 
				
			||||||
 | 
					        "application/x-ctm"
 | 
				
			||||||
 | 
					        "model/vnd.collada+xml"
 | 
				
			||||||
 | 
					        "model/gltf-binary"
 | 
				
			||||||
 | 
					        "model/gltf+json"
 | 
				
			||||||
 | 
					        "model/vnd.collada+xml+zip"
 | 
				
			||||||
 | 
					      ];
 | 
				
			||||||
 | 
					      categories = [ "Graphics" ];
 | 
				
			||||||
 | 
					      keywords = [ "3D" "Printing" ];
 | 
				
			||||||
 | 
					    })
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # TODO: Extract cura-icon from AppImage source.
 | 
				
			||||||
 | 
					  installPhase = ''
 | 
				
			||||||
 | 
					    mkdir -p $out/bin
 | 
				
			||||||
 | 
					    cp ${script}/bin/cura5 $out/bin/cura5
 | 
				
			||||||
 | 
					    runHook postInstall
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = {
 | 
				
			||||||
 | 
					    description = "3D printing software";
 | 
				
			||||||
 | 
					    homepage = "https://github.com/ultimaker/cura";
 | 
				
			||||||
 | 
					    longDescription = ''
 | 
				
			||||||
 | 
					      Cura converts 3D models into paths for a 3D printer. It prepares your print for maximum accuracy, minimum printing time and good reliability with many extra features that make your print come out great.
 | 
				
			||||||
 | 
					    '';
 | 
				
			||||||
 | 
					    license = lib.licenses.lgpl3;
 | 
				
			||||||
 | 
					    platforms = [ "x86_64-linux" ];
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@@ -1,7 +1,7 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, coreutils
 | 
					 | 
				
			||||||
, autoreconfHook
 | 
					, autoreconfHook
 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
 | 
				
			|||||||
    mkdir -p $out/include $out/lib
 | 
					    mkdir -p $out/include $out/lib
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    homepage = "https://github.com/xant/libhl";
 | 
					    homepage = "https://github.com/xant/libhl";
 | 
				
			||||||
    description = "Simple and fast C library implementing a thread-safe API to manage hash-tables, linked lists, lock-free ring buffers and queues ";
 | 
					    description = "Simple and fast C library implementing a thread-safe API to manage hash-tables, linked lists, lock-free ring buffers and queues ";
 | 
				
			||||||
    license = licenses.lgpl3;
 | 
					    license = licenses.lgpl3;
 | 
				
			||||||
@@ -1,4 +1,5 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, autoreconfHook
 | 
					, autoreconfHook
 | 
				
			||||||
@@ -25,10 +26,10 @@ stdenv.mkDerivation rec {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  configureFlags = [ "--with-moduledir=\${out}/lib/security" ];
 | 
					  configureFlags = [ "--with-moduledir=\${out}/lib/security" ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    homepage = "https://github.com/cruegge/pam-gnupg";
 | 
					    homepage = "https://github.com/cruegge/pam-gnupg";
 | 
				
			||||||
    description = "Unlock GnuPG keys on login";
 | 
					    description = "Unlock GnuPG keys on login";
 | 
				
			||||||
    license = licenses.gpl3;
 | 
					    license = licenses.gpl3;
 | 
				
			||||||
    inherit (pam.meta) platforms;
 | 
					    platforms = pam.meta.platforms;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -1,9 +1,10 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, rustPlatform
 | 
					, rustPlatform
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, cmake
 | 
					 | 
				
			||||||
, pkg-config
 | 
					, pkg-config
 | 
				
			||||||
 | 
					, alsaLib
 | 
				
			||||||
 | 
					, dbus
 | 
				
			||||||
, openssl
 | 
					, openssl
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # GUI
 | 
					  # GUI
 | 
				
			||||||
@@ -14,27 +15,27 @@
 | 
				
			|||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
let
 | 
					let
 | 
				
			||||||
  inherit (stdenv.lib) optional optionals;
 | 
					  inherit (lib) optional optionals;
 | 
				
			||||||
in
 | 
					in
 | 
				
			||||||
 | 
					
 | 
				
			||||||
assert withGui -> gtk3.meta.available;
 | 
					assert withGui -> gtk3.meta.available;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
rustPlatform.buildRustPackage rec {
 | 
					rustPlatform.buildRustPackage rec {
 | 
				
			||||||
  pname = "psst";
 | 
					  pname = "psst";
 | 
				
			||||||
  version = "20210122.gec114ac";
 | 
					  version = "20221012.d70ed81";
 | 
				
			||||||
  src = fetchFromGitHub {
 | 
					  src = fetchFromGitHub {
 | 
				
			||||||
    owner = "jpochyla";
 | 
					    owner = "jpochyla";
 | 
				
			||||||
    repo = "psst";
 | 
					    repo = "psst";
 | 
				
			||||||
    rev = "ec114ac8299179c8dd51bc026d6060dc75658b83";
 | 
					    rev = "d70ed8104533dc15bc36b989ba8428872c9b578f";
 | 
				
			||||||
    sha256 = "02mh6hjnlimadc3w899hccss31p1r4sxgb5880zwn7yiycbq3yyj";
 | 
					    hash = "sha256-ZKhHN0ruLb6ZVKkrKv/YawRsVop6SP1QF/nrtkmA8P8=";
 | 
				
			||||||
    fetchSubmodules = true;
 | 
					    fetchSubmodules = true;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
  cargoSha256 = "1m01rycnpy9asspih1x9l5ppfbjnqcfdycmzgkrmdwzah3x8s8xc";
 | 
					  cargoSha256 = "sha256-zH6+EV78FDVOYEFXk0f54pH2Su0QpK1I0bHqzIiMdBo=";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  nativeBuildInputs = [ pkg-config ]
 | 
					  nativeBuildInputs = [ pkg-config ]
 | 
				
			||||||
    ++ optional withGui copyDesktopItems;
 | 
					    ++ optional withGui copyDesktopItems;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  buildInputs = [ openssl ]
 | 
					  buildInputs = [ alsaLib dbus openssl ]
 | 
				
			||||||
    ++ optional withGui gtk3;
 | 
					    ++ optional withGui gtk3;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  cargoBuildFlags = optionals (!withGui) [
 | 
					  cargoBuildFlags = optionals (!withGui) [
 | 
				
			||||||
@@ -54,16 +55,16 @@ rustPlatform.buildRustPackage rec {
 | 
				
			|||||||
      name = pname;
 | 
					      name = pname;
 | 
				
			||||||
      desktopName = "psst";
 | 
					      desktopName = "psst";
 | 
				
			||||||
      genericName = "Spotify Player";
 | 
					      genericName = "Spotify Player";
 | 
				
			||||||
      categories = "AudioVideo;Audio;Network;Player;";
 | 
					      categories = [ "AudioVideo" "Audio" "Network" "Player" ];
 | 
				
			||||||
      comment = "Spotify client with native GUI";
 | 
					      comment = "Spotify client with native GUI";
 | 
				
			||||||
      exec = "psst-gui";
 | 
					      exec = "psst-gui";
 | 
				
			||||||
      extraEntries = "Keywords=spotify;music;";
 | 
					      keywords = [ "spotify" "music" ];
 | 
				
			||||||
      icon = "spotify";
 | 
					      icon = "spotify";
 | 
				
			||||||
      type = "Application";
 | 
					      type = "Application";
 | 
				
			||||||
    })
 | 
					    })
 | 
				
			||||||
  ];
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "Fast and multi-platform Spotify client with native GUI ";
 | 
					    description = "Fast and multi-platform Spotify client with native GUI ";
 | 
				
			||||||
    homepage = "https://github.com/jpochyla/psst";
 | 
					    homepage = "https://github.com/jpochyla/psst";
 | 
				
			||||||
    license = licenses.mit;
 | 
					    license = licenses.mit;
 | 
				
			||||||
@@ -1,7 +1,6 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, makeWrapper
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
, curl
 | 
					, curl
 | 
				
			||||||
, gnumake
 | 
					, gnumake
 | 
				
			||||||
, gnutls
 | 
					, gnutls
 | 
				
			||||||
@@ -40,7 +39,7 @@ stdenv.mkDerivation rec {
 | 
				
			|||||||
      --replace /usr/bin/samrewritten $out/bin/samrewritten
 | 
					      --replace /usr/bin/samrewritten $out/bin/samrewritten
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "Steam Achievement Manager For Linux";
 | 
					    description = "Steam Achievement Manager For Linux";
 | 
				
			||||||
    homepage = "https://github.com/PaulCombal/SamRewritten";
 | 
					    homepage = "https://github.com/PaulCombal/SamRewritten";
 | 
				
			||||||
    license = licenses.gpl3;
 | 
					    license = licenses.gpl3;
 | 
				
			||||||
@@ -2,7 +2,7 @@ diff --git a/setup.py b/setup.py
 | 
				
			|||||||
index a800b3b..8967921 100755
 | 
					index a800b3b..8967921 100755
 | 
				
			||||||
--- a/setup.py
 | 
					--- a/setup.py
 | 
				
			||||||
+++ b/setup.py
 | 
					+++ b/setup.py
 | 
				
			||||||
@@ -22,14 +22,13 @@ setup(
 | 
					@@ -33,14 +33,13 @@ setup(
 | 
				
			||||||
     name='spotify-ripper',
 | 
					     name='spotify-ripper',
 | 
				
			||||||
     version='2.9.1',
 | 
					     version='2.9.1',
 | 
				
			||||||
     packages=find_packages(exclude=["tests"]),
 | 
					     packages=find_packages(exclude=["tests"]),
 | 
				
			||||||
@@ -18,11 +18,7 @@ index a800b3b..8967921 100755
 | 
				
			|||||||
         ],
 | 
					         ],
 | 
				
			||||||
     },
 | 
					     },
 | 
				
			||||||
 
 | 
					 
 | 
				
			||||||
@@ -67,7 +66,5 @@ setup(
 | 
					@@ -121,3 +121,2 @@ setup(
 | 
				
			||||||
         'Programming Language :: Python :: 3',
 | 
					     return True
 | 
				
			||||||
         'Programming Language :: Python :: 3.4',
 | 
					 | 
				
			||||||
     ],
 | 
					 | 
				
			||||||
-    long_description=_read('README.rst'),
 | 
					 | 
				
			||||||
 )
 | 
					 | 
				
			||||||
 
 | 
					 
 | 
				
			||||||
-create_default_dir()
 | 
					-create_default_dir()
 | 
				
			||||||
@@ -1,42 +1,52 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, python2Packages
 | 
					, python3Packages
 | 
				
			||||||
 | 
					, lame
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, aacSupport ? false, faac
 | 
					, aacSupport ? false
 | 
				
			||||||
, alacSupport ? false, libav
 | 
					, faac
 | 
				
			||||||
, flacSupport ? false, flac
 | 
					, alacSupport ? false
 | 
				
			||||||
, m4aSupport ? false, mp4Support ? false, fdk-aac-encoder
 | 
					, libav
 | 
				
			||||||
, oggSupport ? false, vorbisTools
 | 
					, flacSupport ? false
 | 
				
			||||||
, opusSupport ? false, opusTools
 | 
					, flac
 | 
				
			||||||
 | 
					, m4aSupport ? false
 | 
				
			||||||
 | 
					, mp4Support ? false
 | 
				
			||||||
 | 
					, fdk-aac-encoder
 | 
				
			||||||
 | 
					, oggSupport ? false
 | 
				
			||||||
 | 
					, vorbisTools
 | 
				
			||||||
 | 
					, opusSupport ? false
 | 
				
			||||||
 | 
					, opusTools
 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
assert aacSupport               -> faac.meta.available;
 | 
					assert aacSupport -> faac.meta.available;
 | 
				
			||||||
assert alacSupport              -> libav.meta.available;
 | 
					assert alacSupport -> libav.meta.available;
 | 
				
			||||||
assert flacSupport              -> flac.meta.available;
 | 
					assert flacSupport -> flac.meta.available;
 | 
				
			||||||
assert m4aSupport || mp4Support -> fdk-aac-encoder.meta.available;
 | 
					assert m4aSupport || mp4Support -> fdk-aac-encoder.meta.available;
 | 
				
			||||||
assert oggSupport               -> vorbisTools.meta.available;
 | 
					assert oggSupport -> vorbisTools.meta.available;
 | 
				
			||||||
assert opusSupport              -> opusTools.meta.available;
 | 
					assert opusSupport -> opusTools.meta.available;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
python2Packages.buildPythonApplication rec {
 | 
					python3Packages.buildPythonApplication rec {
 | 
				
			||||||
  pname = "spotify-ripper";
 | 
					  pname = "spotify-ripper";
 | 
				
			||||||
  version = "20161231.gd046419";
 | 
					  version = "20210724.5bfd3f7";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  src = fetchFromGitHub {
 | 
					  src = fetchFromGitHub {
 | 
				
			||||||
    owner = "hbashton";
 | 
					    owner = "ast261";
 | 
				
			||||||
    repo = pname;
 | 
					    repo = pname;
 | 
				
			||||||
    rev = "d0464193dead7bd3ac7580e98bde86a0f323acae";
 | 
					    rev = "5bfd3f7a52f2767b433fd315145409837a3c33f0";
 | 
				
			||||||
    sha256 = "003d6br20f1cf4qvmpl62bk0k4h4v66ib76wn36c23bnh9x5q806";
 | 
					    sha256 = "sha256-LLunGzs9Mg4S00Su260b+M5w/XwS+kICl/YXQdR/cPI=";
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  propagatedBuildInputs = (with python2Packages; [
 | 
					  propagatedBuildInputs = (with python3Packages; [
 | 
				
			||||||
    colorama
 | 
					    colorama
 | 
				
			||||||
    mutagen
 | 
					    mutagen
 | 
				
			||||||
    pyspotify
 | 
					    pyspotify
 | 
				
			||||||
    requests
 | 
					    requests
 | 
				
			||||||
    schedule
 | 
					    schedule
 | 
				
			||||||
    setuptools
 | 
					    setuptools
 | 
				
			||||||
 | 
					    spotipy
 | 
				
			||||||
  ]) ++ [
 | 
					  ]) ++ [
 | 
				
			||||||
 | 
					    lame
 | 
				
			||||||
    (if flacSupport then flac else null)
 | 
					    (if flacSupport then flac else null)
 | 
				
			||||||
    (if alacSupport then libav else null)
 | 
					    (if alacSupport then libav else null)
 | 
				
			||||||
    (if aacSupport then faac else null)
 | 
					    (if aacSupport then faac else null)
 | 
				
			||||||
@@ -48,7 +58,7 @@ python2Packages.buildPythonApplication rec {
 | 
				
			|||||||
  # Remove impure executables.
 | 
					  # Remove impure executables.
 | 
				
			||||||
  patches = [ ./fix-setup.patch ];
 | 
					  patches = [ ./fix-setup.patch ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "Rip Spotify URIs to audio files, including ID3 tags and cover art";
 | 
					    description = "Rip Spotify URIs to audio files, including ID3 tags and cover art";
 | 
				
			||||||
    longDescription = ''
 | 
					    longDescription = ''
 | 
				
			||||||
      Spotify-ripper is a small ripper script for Spotify that rips Spotify URIs
 | 
					      Spotify-ripper is a small ripper script for Spotify that rips Spotify URIs
 | 
				
			||||||
@@ -58,6 +68,6 @@ python2Packages.buildPythonApplication rec {
 | 
				
			|||||||
    '';
 | 
					    '';
 | 
				
			||||||
    homepage = "https://github.com/hbashton/spotify-ripper";
 | 
					    homepage = "https://github.com/hbashton/spotify-ripper";
 | 
				
			||||||
    # spotify-ripper itself is MIT, but the upstream libspotify is unfree.
 | 
					    # spotify-ripper itself is MIT, but the upstream libspotify is unfree.
 | 
				
			||||||
    license = stdenv.lib.licenses.unfree;
 | 
					    license = licenses.unfree;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
							
								
								
									
										38
									
								
								pkgs/by-name/yt/ytarchive/package.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										38
									
								
								pkgs/by-name/yt/ytarchive/package.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,38 @@
 | 
				
			|||||||
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					, python3
 | 
				
			||||||
 | 
					, ffmpeg
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					stdenv.mkDerivation rec {
 | 
				
			||||||
 | 
					  pname = "ytarchive";
 | 
				
			||||||
 | 
					  version = "0.2.2+0304577";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  src = fetchFromGitHub {
 | 
				
			||||||
 | 
					    owner = "Kethsar";
 | 
				
			||||||
 | 
					    repo = "ytarchive";
 | 
				
			||||||
 | 
					    # NOTE: Last revision where it was written in Python, so don't change
 | 
				
			||||||
 | 
					    #   without rewriting the derivation.
 | 
				
			||||||
 | 
					    rev = "030457749d6c8d1d62240bfbad659326f3cd3a30";
 | 
				
			||||||
 | 
					    hash = "sha256-mvmdkxZxlEbWc7GR8LfyxTJOeEhjCoYyeatDx8l1uhM=";
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  propagatedBuildInputs = [
 | 
				
			||||||
 | 
					    python3
 | 
				
			||||||
 | 
					    ffmpeg
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  phases = [ "unpackPhase" "installPhase" "fixupPhase" ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  installPhase = ''
 | 
				
			||||||
 | 
					    install -Dm00755 ytarchive.py $out/bin/ytarchive
 | 
				
			||||||
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  meta = with lib; {
 | 
				
			||||||
 | 
					    description = "Garbage Youtube livestream downloader";
 | 
				
			||||||
 | 
					    homepage = "https://github.com/Kethsar/ytarchive";
 | 
				
			||||||
 | 
					    license = licenses.mit;
 | 
				
			||||||
 | 
					    platforms = python3.meta.platforms;
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@@ -1,4 +1,5 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, installShellFiles
 | 
					, installShellFiles
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -25,10 +26,10 @@ stdenv.mkDerivation {
 | 
				
			|||||||
    installShellCompletion --zsh _zshz
 | 
					    installShellCompletion --zsh _zshz
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = ''Jump quickly to directories that you have visited "frecently." A native ZSH port of z.sh.'';
 | 
					    description = ''Jump quickly to directories that you have visited "frecently." A native ZSH port of z.sh.'';
 | 
				
			||||||
    homepage = "https://github.com/agkozak/zsh-z";
 | 
					    homepage = "https://github.com/agkozak/zsh-z";
 | 
				
			||||||
    license = stdenv.lib.licenses.mit;
 | 
					    license = licenses.mit;
 | 
				
			||||||
    platforms = zsh.meta.platforms;
 | 
					    platforms = zsh.meta.platforms;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
, buildGoModule
 | 
					, buildGoModule
 | 
				
			||||||
, makeWrapper
 | 
					, makeWrapper
 | 
				
			||||||
@@ -59,9 +59,10 @@ buildGoModule rec {
 | 
				
			|||||||
    done
 | 
					    done
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    homepage = "https://github.com/therecipe/qt";
 | 
					    homepage = "https://github.com/therecipe/qt";
 | 
				
			||||||
    description = "Qt bindings for Go";
 | 
					    description = "Qt bindings for Go";
 | 
				
			||||||
    license = licenses.lgpl3;
 | 
					    license = licenses.lgpl3;
 | 
				
			||||||
 | 
					    broken = true;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ lib
 | 
				
			||||||
, buildPythonPackage
 | 
					, buildPythonPackage
 | 
				
			||||||
, fetchPypi
 | 
					, fetchPypi
 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
@@ -14,9 +14,9 @@ buildPythonPackage rec {
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  doCheck = false;
 | 
					  doCheck = false;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = {
 | 
					  meta = with lib; {
 | 
				
			||||||
    homepage = "https://stuffivelearned.org/doku.php?id=programming:python:py-sonic";
 | 
					    homepage = "https://stuffivelearned.org/doku.php?id=programming:python:py-sonic";
 | 
				
			||||||
    license = stdenv.lib.licenses.gpl3;
 | 
					    license = licenses.gpl3;
 | 
				
			||||||
    description = "A python wrapper library for the Subsonic REST API";
 | 
					    description = "A python wrapper library for the Subsonic REST API";
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,16 +1,18 @@
 | 
				
			|||||||
{ stdenv
 | 
					{ stdenv
 | 
				
			||||||
 | 
					, lib
 | 
				
			||||||
, fetchFromGitHub
 | 
					, fetchFromGitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
, qtbase
 | 
					, qtbase
 | 
				
			||||||
, qmake
 | 
					, qmake
 | 
				
			||||||
 | 
					, wrapQtAppsHook ? null # Temporary backwards compatibility
 | 
				
			||||||
}:
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
stdenv.mkDerivation rec {
 | 
					stdenv.mkDerivation rec {
 | 
				
			||||||
  pname = "radeon-profile-daemon";
 | 
					  pname = "radeon-profile-daemon";
 | 
				
			||||||
  version = "20190603.g06qxq2h";
 | 
					  version = "20190603.g06qxq2h";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  nativeBuildInputs = [ qmake ];
 | 
					 | 
				
			||||||
  buildInputs = [ qtbase ];
 | 
					  buildInputs = [ qtbase ];
 | 
				
			||||||
 | 
					  nativeBuildInputs = [ qmake wrapQtAppsHook ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  src = (
 | 
					  src = (
 | 
				
			||||||
    fetchFromGitHub {
 | 
					    fetchFromGitHub {
 | 
				
			||||||
@@ -26,7 +28,7 @@ stdenv.mkDerivation rec {
 | 
				
			|||||||
      --replace "/usr/" "$out/"
 | 
					      --replace "/usr/" "$out/"
 | 
				
			||||||
  '';
 | 
					  '';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  meta = with stdenv.lib; {
 | 
					  meta = with lib; {
 | 
				
			||||||
    description = "System daemon for reading current clocks of AMD Radeon cards";
 | 
					    description = "System daemon for reading current clocks of AMD Radeon cards";
 | 
				
			||||||
    homepage = "https://github.com/marazmista/radeon-profile-daemon";
 | 
					    homepage = "https://github.com/marazmista/radeon-profile-daemon";
 | 
				
			||||||
    license = licenses.gpl2Plus;
 | 
					    license = licenses.gpl2Plus;
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,55 +1,8 @@
 | 
				
			|||||||
{ pkgs }:
 | 
					{ pkgs }:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
rec {
 | 
					rec {
 | 
				
			||||||
  # Alacritty with the unmerged ligature patches applied.
 | 
					 | 
				
			||||||
  alacritty-ligatures = pkgs.alacritty.overrideAttrs (oldAttrs: rec {
 | 
					 | 
				
			||||||
    pname = "${oldAttrs.pname}-ligatures";
 | 
					 | 
				
			||||||
    version = "0.7.1.20210107.gada2680";
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    src = pkgs.fetchFromGitHub {
 | 
					 | 
				
			||||||
      owner = "zenixls2";
 | 
					 | 
				
			||||||
      repo = "alacritty";
 | 
					 | 
				
			||||||
      fetchSubmodules = true;
 | 
					 | 
				
			||||||
      rev = "ada2680e79a8f53cd350263c8cc91d2e2a264d81";
 | 
					 | 
				
			||||||
      sha256 = "0c0k1ib1dl35731zyjb32apyn28xc63mhbwsig5mz3hnkyk5nisr";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    cargoDeps = oldAttrs.cargoDeps.overrideAttrs (pkgs.lib.const {
 | 
					 | 
				
			||||||
      name = "${pname}-${version}-vendor.tar.gz";
 | 
					 | 
				
			||||||
      inherit src;
 | 
					 | 
				
			||||||
      outputHash = "1d1yz4xmal0f3c0pcn59lxfh5a3532nv7dv7s95svvi8qsvnk9gv";
 | 
					 | 
				
			||||||
    });
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    ligatureInputs = [
 | 
					 | 
				
			||||||
      pkgs.fontconfig
 | 
					 | 
				
			||||||
      pkgs.freetype
 | 
					 | 
				
			||||||
      pkgs.libglvnd
 | 
					 | 
				
			||||||
      pkgs.stdenv.cc.cc.lib
 | 
					 | 
				
			||||||
      pkgs.xlibs.libxcb
 | 
					 | 
				
			||||||
    ];
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    buildInputs = (oldAttrs.buildInputs or []) ++ ligatureInputs;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    # HACK: One of the ligature libraries required the C++ stdlib at runtime,
 | 
					 | 
				
			||||||
    # and I can't work out a better way to push it to the RPATH.
 | 
					 | 
				
			||||||
    postInstall = pkgs.lib.optional (!pkgs.stdenv.isDarwin) ''
 | 
					 | 
				
			||||||
      patchelf \
 | 
					 | 
				
			||||||
        --set-rpath ${pkgs.lib.makeLibraryPath ligatureInputs}:"$(patchelf --show-rpath $out/bin/alacritty)" \
 | 
					 | 
				
			||||||
        $out/bin/alacritty
 | 
					 | 
				
			||||||
    '';
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    meta = oldAttrs.meta // {
 | 
					 | 
				
			||||||
      description = "Alacritty with ligature patch applied";
 | 
					 | 
				
			||||||
      homepage = "https://github.com/zenixls2/alacritty/tree/ligature";
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
  });
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  amdgpu-fan = pkgs.callPackage ../tools/misc/amdgpu-fan { };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  cardboard = pkgs.callPackage ../applications/window-managers/cardboard { };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  goModules = pkgs.recurseIntoAttrs rec {
 | 
					  goModules = pkgs.recurseIntoAttrs rec {
 | 
				
			||||||
    qt = pkgs.libsForQt512.callPackage ../development/go-modules/qt { };
 | 
					    qt = pkgs.libsForQt5.callPackage ../development/go-modules/qt { };
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # A functional Jetbrains IDE-with-plugins package set.
 | 
					  # A functional Jetbrains IDE-with-plugins package set.
 | 
				
			||||||
@@ -72,15 +25,11 @@ rec {
 | 
				
			|||||||
    ideaUltimateWithPlugins = ideaUltimatePlugins.jetbrainsWithPlugins;
 | 
					    ideaUltimateWithPlugins = ideaUltimatePlugins.jetbrainsWithPlugins;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  libhl = pkgs.callPackage ../development/libraries/libhl { };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  mopidy-subidy = pkgs.callPackage ../applications/audio/mopidy/subidy.nix {
 | 
					  mopidy-subidy = pkgs.callPackage ../applications/audio/mopidy/subidy.nix {
 | 
				
			||||||
    python3Packages = pkgs.python3Packages // python3Packages;
 | 
					    python3Packages = pkgs.python3Packages // python3Packages;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  pam_gnupg = pkgs.callPackage ../os-specific/linux/pam_gnupg { };
 | 
					  picom-animations = pkgs.picom.overrideAttrs (_oldAttrs: {
 | 
				
			||||||
 | 
					 | 
				
			||||||
  picom-animations = pkgs.picom.overrideAttrs (oldAttrs: {
 | 
					 | 
				
			||||||
    pname = "picom-animations";
 | 
					    pname = "picom-animations";
 | 
				
			||||||
    src = pkgs.fetchFromGitHub {
 | 
					    src = pkgs.fetchFromGitHub {
 | 
				
			||||||
      owner = "jonaburg";
 | 
					      owner = "jonaburg";
 | 
				
			||||||
@@ -96,74 +45,17 @@ rec {
 | 
				
			|||||||
    patches = (oldAttrs.patches or [ ]) ++ [ ../applications/misc/polybar/9button.patch ];
 | 
					    patches = (oldAttrs.patches or [ ]) ++ [ ../applications/misc/polybar/9button.patch ];
 | 
				
			||||||
  });
 | 
					  });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  psst = pkgs.callPackage ../applications/audio/psst { };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  python2Packages =
 | 
					 | 
				
			||||||
    let
 | 
					 | 
				
			||||||
      fixVersion =
 | 
					 | 
				
			||||||
        { package
 | 
					 | 
				
			||||||
        , version
 | 
					 | 
				
			||||||
        , sha256
 | 
					 | 
				
			||||||
        , extra ? (oldAttrs: { })
 | 
					 | 
				
			||||||
        }: package.overrideAttrs (oldAttrs: rec {
 | 
					 | 
				
			||||||
          inherit version;
 | 
					 | 
				
			||||||
          src = pkgs.python2Packages.fetchPypi {
 | 
					 | 
				
			||||||
            inherit (oldAttrs) pname;
 | 
					 | 
				
			||||||
            inherit version sha256;
 | 
					 | 
				
			||||||
          };
 | 
					 | 
				
			||||||
        } // extra oldAttrs);
 | 
					 | 
				
			||||||
    in
 | 
					 | 
				
			||||||
    pkgs.recurseIntoAttrs rec {
 | 
					 | 
				
			||||||
      colorama_0_3_3 = fixVersion {
 | 
					 | 
				
			||||||
        package = pkgs.python2Packages.colorama;
 | 
					 | 
				
			||||||
        version = "0.3.3";
 | 
					 | 
				
			||||||
        sha256 = "1716z9pq1r5ys3nkg7wdrb3h2f9rmd0zdxpxzmx3bgwgf6xg48gb";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      mutagen_1_30 = fixVersion {
 | 
					 | 
				
			||||||
        package = pkgs.python2Packages.mutagen;
 | 
					 | 
				
			||||||
        version = "1.30";
 | 
					 | 
				
			||||||
        sha256 = "0kv2gjnzbj1w0bswmxm7wi05x6ypi7jk52s0lb8gw8s459j41gyd";
 | 
					 | 
				
			||||||
        extra = oldAttrs: {
 | 
					 | 
				
			||||||
          patches = [ ];
 | 
					 | 
				
			||||||
        };
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      pyspotify_2_0_5 = fixVersion {
 | 
					 | 
				
			||||||
        package = pkgs.python2Packages.pyspotify;
 | 
					 | 
				
			||||||
        version = "2.0.5";
 | 
					 | 
				
			||||||
        sha256 = "0y16c024rrvbvfdqj1n0k4b25b1nbza3i7kspg5b0ci2src1rm7v";
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
      overlay = {
 | 
					 | 
				
			||||||
        colorama = colorama_0_3_3;
 | 
					 | 
				
			||||||
        mutagen = mutagen_1_30;
 | 
					 | 
				
			||||||
        pyspotify = pyspotify_2_0_5;
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  python3Packages = pkgs.recurseIntoAttrs {
 | 
					  python3Packages = pkgs.recurseIntoAttrs {
 | 
				
			||||||
    py-sonic = pkgs.python3.pkgs.callPackage ../development/python-modules/py-sonic { };
 | 
					    py-sonic = pkgs.python3.pkgs.callPackage ../development/python-modules/py-sonic { };
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  # The one in Nixpkgs still extracts the pre-built Debian package instead
 | 
					  # The one in Nixpkgs still extracts the pre-built Debian package instead
 | 
				
			||||||
  # of building from source.
 | 
					  # of building from source.
 | 
				
			||||||
  protonmailBridgePackages = pkgs.libsForQt512.callPackage ../applications/networking/protonmail-bridge {
 | 
					  protonmailBridgePackages = pkgs.libsForQt5.callPackage ../applications/networking/protonmail-bridge {
 | 
				
			||||||
    inherit goModules;
 | 
					    inherit goModules;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
  protonmail-bridge = protonmailBridgePackages.protonmail-bridge;
 | 
					  protonmail-bridge = protonmailBridgePackages.protonmail-bridge;
 | 
				
			||||||
  protonmail-bridge-headless = protonmailBridgePackages.protonmail-bridge-headless;
 | 
					  protonmail-bridge-headless = protonmailBridgePackages.protonmail-bridge-headless;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  radeon-profile-daemon = pkgs.libsForQt5.callPackage ../tools/misc/radeon-profile-daemon { };
 | 
					  radeon-profile-daemon = pkgs.libsForQt5.callPackage ../tools/misc/radeon-profile-daemon { };
 | 
				
			||||||
 | 
					 | 
				
			||||||
  samrewritten = pkgs.callPackage ../tools/misc/samrewritten { };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  spotify-ripper = pkgs.callPackage ../tools/misc/spotify-ripper {
 | 
					 | 
				
			||||||
    # NOTE: Not available in 20.03. Specifying it this way lets me cheat the
 | 
					 | 
				
			||||||
    # build auto-failing on 20.03 because of the attribute not existing.
 | 
					 | 
				
			||||||
    inherit (pkgs) fdk-aac-encoder;
 | 
					 | 
				
			||||||
    python2Packages = pkgs.python2Packages // python2Packages.overlay;
 | 
					 | 
				
			||||||
  };
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  zsh-z = pkgs.callPackage ../shells/zsh/zsh-z { };
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										56
									
								
								pkgs/top-level/by-name-overlay.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										56
									
								
								pkgs/top-level/by-name-overlay.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,56 @@
 | 
				
			|||||||
 | 
					# This file turns the pkgs/by-name directory (see its README.md for more info)
 | 
				
			||||||
 | 
					# into an overlay that adds all the defined packages.
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# No validity checks are done here, instead this file is optimised for
 | 
				
			||||||
 | 
					# performance, and validity checks are done by CI on PRs.
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# This file is based on Nixpkgs' `pkgs/top-level/by-name-overlay.nix` in order
 | 
				
			||||||
 | 
					# to utilise the same infrastructure and layout, with some adjustments to fit
 | 
				
			||||||
 | 
					# our derivative project.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{ lib
 | 
				
			||||||
 | 
					, pkgs
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Type: Path -> Overlay
 | 
				
			||||||
 | 
					baseDirectory:
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					  inherit (builtins)
 | 
				
			||||||
 | 
					    readDir
 | 
				
			||||||
 | 
					    ;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  inherit (lib.attrsets)
 | 
				
			||||||
 | 
					    mapAttrs
 | 
				
			||||||
 | 
					    mapAttrsToList
 | 
				
			||||||
 | 
					    mergeAttrsList
 | 
				
			||||||
 | 
					    ;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # Package files for a single shard
 | 
				
			||||||
 | 
					  # Type: String -> String -> AttrsOf Path
 | 
				
			||||||
 | 
					  namesForShard = shard: type:
 | 
				
			||||||
 | 
					    if type != "directory" then
 | 
				
			||||||
 | 
					    # Ignore all non-directories. Technically only README.md is allowed as a file in the base directory, so we could alternatively:
 | 
				
			||||||
 | 
					    # - Assume that README.md is the only file and change the condition to `shard == "README.md"` for a minor performance improvement.
 | 
				
			||||||
 | 
					    #   This would however cause very poor error messages if there's other files.
 | 
				
			||||||
 | 
					    # - Ensure that README.md is the only file, throwing a better error message if that's not the case.
 | 
				
			||||||
 | 
					    #   However this would make for a poor code architecture, because one type of error would have to be duplicated in the validity checks and here.
 | 
				
			||||||
 | 
					    # Additionally in either of those alternatives, we would have to duplicate the hardcoding of "README.md"
 | 
				
			||||||
 | 
					      { }
 | 
				
			||||||
 | 
					    else
 | 
				
			||||||
 | 
					      mapAttrs
 | 
				
			||||||
 | 
					        (name: _: baseDirectory + "/${shard}/${name}/package.nix")
 | 
				
			||||||
 | 
					        (readDir (baseDirectory + "/${shard}"));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # The attribute set mapping names to the package files defining them
 | 
				
			||||||
 | 
					  # This is defined up here in order to allow reuse of the value (it's kind of expensive to compute)
 | 
				
			||||||
 | 
					  # if the overlay has to be applied multiple times
 | 
				
			||||||
 | 
					  packageFiles = mergeAttrsList (mapAttrsToList namesForShard (readDir baseDirectory));
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					# TODO: Consider optimising this using `builtins.deepSeq packageFiles`,
 | 
				
			||||||
 | 
					  # which could free up the above thunks and reduce GC times.
 | 
				
			||||||
 | 
					  # Currently this would be hard to measure until we have more packages
 | 
				
			||||||
 | 
					  # and ideally https://github.com/NixOS/nix/pull/8895
 | 
				
			||||||
 | 
					_self: _super:
 | 
				
			||||||
 | 
					mapAttrs
 | 
				
			||||||
 | 
					  (_name: file: pkgs.callPackage file { })
 | 
				
			||||||
 | 
					  packageFiles
 | 
				
			||||||
							
								
								
									
										19
									
								
								pkgs/top-level/default.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								pkgs/top-level/default.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
				
			|||||||
 | 
					# Composes the packages collection.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					  # The system packages will be build and used on.
 | 
				
			||||||
 | 
					  localSystem
 | 
				
			||||||
 | 
					  # Nixpkgs
 | 
				
			||||||
 | 
					, pkgs
 | 
				
			||||||
 | 
					  # Nixpkgs lib
 | 
				
			||||||
 | 
					, lib ? pkgs.lib
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					  allPackages = import ./stage.nix {
 | 
				
			||||||
 | 
					    inherit lib pkgs;
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  available = lib.filterAttrs
 | 
				
			||||||
 | 
					    (_: drv: builtins.elem localSystem (drv.meta.platforms or [ ]));
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					available allPackages
 | 
				
			||||||
@@ -20,14 +20,16 @@ let
 | 
				
			|||||||
    inherit lib;
 | 
					    inherit lib;
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
in lib.makeScope newScope (self: lib.makeOverridable ({
 | 
					in
 | 
				
			||||||
  jetbrainsPlugins ? mkJetbrainsPlugins self
 | 
					lib.makeScope newScope (self: lib.makeOverridable
 | 
				
			||||||
  , ideaPlugins ? mkIdeaPlugins self
 | 
					  ({ jetbrainsPlugins ? mkJetbrainsPlugins self
 | 
				
			||||||
}: ({ }
 | 
					   , ideaPlugins ? mkIdeaPlugins self
 | 
				
			||||||
  // jetbrainsPlugins // { inherit jetbrainsPlugins; }
 | 
					   }: ({ }
 | 
				
			||||||
  // ideaPlugins // { inherit ideaPlugins; }
 | 
					    // jetbrainsPlugins // { inherit jetbrainsPlugins; }
 | 
				
			||||||
  // {
 | 
					    // ideaPlugins // { inherit ideaPlugins; }
 | 
				
			||||||
 | 
					    // {
 | 
				
			||||||
    inherit variant;
 | 
					    inherit variant;
 | 
				
			||||||
    jetbrainsWithPlugins = jetbrainsWithPlugins self variant;
 | 
					    jetbrainsWithPlugins = jetbrainsWithPlugins self variant;
 | 
				
			||||||
  })
 | 
					  })
 | 
				
			||||||
) { })
 | 
					  )
 | 
				
			||||||
 | 
					{ })
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										24
									
								
								pkgs/top-level/stage.nix
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								pkgs/top-level/stage.nix
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
				
			|||||||
 | 
					# Composes a single bootstrapping of the package collection. The result is a set
 | 
				
			||||||
 | 
					# of all the packages for some particular platform.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					{ lib
 | 
				
			||||||
 | 
					, pkgs
 | 
				
			||||||
 | 
					}:
 | 
				
			||||||
 | 
					let
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # An overlay to auto-call packages in .../by-name.
 | 
				
			||||||
 | 
					  autoCalledPackages =
 | 
				
			||||||
 | 
					    import ./by-name-overlay.nix { inherit pkgs lib; } ../by-name;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  allPackages = _self: _super:
 | 
				
			||||||
 | 
					    import ./all-packages.nix { inherit pkgs; };
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  toFix = (lib.flip lib.composeManyExtensions) (_self: { }) [
 | 
				
			||||||
 | 
					    autoCalledPackages
 | 
				
			||||||
 | 
					    allPackages
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					in
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Return the complete set of packages.
 | 
				
			||||||
 | 
					lib.fix toFix
 | 
				
			||||||
		Reference in New Issue
	
	Block a user