treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchFromGitHub, cmake, git, gfortran, openmpi, blas, liblapack, qt4, qwt6_qt4, pkg-config }:
|
||||
{ lib, stdenv, fetchFromGitHub, cmake, git, gfortran, openmpi, blas, liblapack, qt4, qwt6_qt4, pkg-config }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "elmerfem";
|
||||
@@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
|
||||
./fix-cmake.patch
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
meta = with lib; {
|
||||
homepage = "https://elmerfem.org/";
|
||||
description = "A finite element software for multiphysical problems";
|
||||
platforms = platforms.unix;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, jre, makeWrapper }:
|
||||
{ lib, stdenv, fetchurl, jre, makeWrapper }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "quantomatic";
|
||||
@@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
|
||||
makeWrapper ${jre}/bin/java $out/bin/quantomatic --add-flags "-jar $out/libexec/quantomatic/quantomatic.jar"
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
meta = with lib; {
|
||||
description = "A piece of software for reasoning about monoidal theories; in particular, quantum information processing";
|
||||
license = licenses.gpl3;
|
||||
homepage = "https://quantomatic.github.io/";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, gfortran, hepmc2, fastjet, lhapdf, rivet, sqlite }:
|
||||
{ lib, stdenv, fetchurl, gfortran, hepmc2, fastjet, lhapdf, rivet, sqlite }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "sherpa";
|
||||
@@ -25,7 +25,7 @@ stdenv.mkDerivation rec {
|
||||
"--enable-rivet=${rivet}"
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
meta = with lib; {
|
||||
description = "Simulation of High-Energy Reactions of PArticles in lepton-lepton, lepton-photon, photon-photon, lepton-hadron and hadron-hadron collisions";
|
||||
license = licenses.gpl2;
|
||||
homepage = "https://gitlab.com/sherpa-team/sherpa";
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, apfel, apfelgrid, applgrid, blas, gfortran, lhapdf, lapack, libyaml, lynx
|
||||
{ lib, stdenv, fetchurl, apfel, apfelgrid, applgrid, blas, gfortran, lhapdf, lapack, libyaml, lynx
|
||||
, mela, root5, qcdnum, which, libtirpc
|
||||
}:
|
||||
|
||||
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
|
||||
NIX_CFLAGS_COMPILE = [ "-I${libtirpc.dev}/include/tirpc" ];
|
||||
NIX_LDFLAGS = [ "-ltirpc" ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
meta = with lib; {
|
||||
description = "The xFitter project is an open source QCD fit framework ready to extract PDFs and assess the impact of new data";
|
||||
license = licenses.gpl3;
|
||||
homepage = "https://www.xfitter.org/xFitter";
|
||||
|
||||
Reference in New Issue
Block a user