From 4a7f99d55d299453a9c2397f90b33d1120669775 Mon Sep 17 00:00:00 2001 From: Profpatsch Date: Mon, 11 Jan 2021 08:54:33 +0100 Subject: treewide: with stdenv.lib; in meta -> with lib; MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 --- pkgs/applications/video/obs-studio/default.nix | 4 ++-- pkgs/applications/video/obs-studio/obs-ndi.nix | 4 ++-- pkgs/applications/video/obs-studio/wlrobs.nix | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'pkgs/applications/video/obs-studio') diff --git a/pkgs/applications/video/obs-studio/default.nix b/pkgs/applications/video/obs-studio/default.nix index cdecde6b869af..1f8357324ea39 100644 --- a/pkgs/applications/video/obs-studio/default.nix +++ b/pkgs/applications/video/obs-studio/default.nix @@ -1,4 +1,4 @@ -{ config, stdenv +{ config, lib, stdenv , mkDerivation , fetchFromGitHub , addOpenGLRunpath @@ -110,7 +110,7 @@ in mkDerivation rec { addOpenGLRunpath $out/lib/obs-plugins/*.so ''; - meta = with stdenv.lib; { + meta = with lib; { description = "Free and open source software for video recording and live streaming"; longDescription = '' This project is a rewrite of what was formerly known as "Open Broadcaster diff --git a/pkgs/applications/video/obs-studio/obs-ndi.nix b/pkgs/applications/video/obs-studio/obs-ndi.nix index a250a365ac63b..d9867b1bb2d25 100644 --- a/pkgs/applications/video/obs-studio/obs-ndi.nix +++ b/pkgs/applications/video/obs-studio/obs-ndi.nix @@ -5,7 +5,7 @@ # mkdir -p ~/.config/obs-studio/plugins/bin # ln -s ~/.nix-profile/lib/obs-plugins/obs-ndi.so ~/.config/obs-studio/plugins/bin/ -{ stdenv, fetchFromGitHub, obs-studio, cmake, qtbase, ndi }: +{ lib, stdenv, fetchFromGitHub, obs-studio, cmake, qtbase, ndi }: stdenv.mkDerivation rec { pname = "obs-ndi"; @@ -31,7 +31,7 @@ stdenv.mkDerivation rec { "-DCMAKE_CXX_FLAGS=-I${obs-studio.src}/UI/obs-frontend-api" ]; - meta = with stdenv.lib; { + meta = with lib; { description = "Network A/V plugin for OBS Studio"; homepage = "https://github.com/Palakis/obs-ndi"; maintainers = with maintainers; [ peti jshcmpbll ]; diff --git a/pkgs/applications/video/obs-studio/wlrobs.nix b/pkgs/applications/video/obs-studio/wlrobs.nix index 14bc80dd38809..eba1508387b76 100644 --- a/pkgs/applications/video/obs-studio/wlrobs.nix +++ b/pkgs/applications/video/obs-studio/wlrobs.nix @@ -32,7 +32,7 @@ stdenv.mkDerivation { "-Duse_dmabuf=${lib.boolToString dmabufSupport}" ]; - meta = with stdenv.lib; { + meta = with lib; { description = "An obs-studio plugin that allows you to screen capture on wlroots based wayland compositors"; homepage = "https://hg.sr.ht/~scoopta/wlrobs"; maintainers = with maintainers; [ grahamc ]; -- cgit 1.4.1