Skip to content
This repository was archived by the owner on Apr 12, 2021. It is now read-only.
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: bc41317e2431
Choose a base ref
...
head repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: f2a1a4e93be2
Choose a head ref

Commits on Oct 2, 2018

  1. Copy the full SHA
    45df055 View commit details
  2. maintainers/maintainer-list.nix: stop the real name policy

    What is a "real name" anyway? Are we in the buisness of checking passports here?
    oxij committed Oct 2, 2018
    Copy the full SHA
    5abdbbb View commit details

Commits on Oct 3, 2018

  1. Copy the full SHA
    be68971 View commit details
  2. Copy the full SHA
    419ea86 View commit details

Commits on Oct 8, 2018

  1. Copy the full SHA
    5828821 View commit details

Commits on Oct 9, 2018

  1. qcdnum: downgrade 17-01-14 -> 17-01-13

    17-01-14 is not compatible with xfitter. It fails with:
    
      PDFEXT obsolete, please use EXTPDF instead
    veprbl committed Oct 9, 2018
    Copy the full SHA
    ad6b9e4 View commit details

Commits on Oct 10, 2018

  1. nixos-option: don't abort with shell failures if options are not exis…

    …tant
    
    `nixos-option` basically handles two cases: the given option is either a
    valid option defined using `mkOption` or an attribute set which contains
    a set of options.
    
    If none of the above cases is valid, `$1` is invalid. Unfortunatley the
    script interpreted invalid options as an attribute set which rendered
    shell failures when trying to evaluate the arguments.
    
    First of all, `if names=$(attrNames ...)` resulted in `<PRIMOP>` as
    `attrNames` simply evaluated `builtins.attrNames $result` which results
    in a non-applied function with `$result` being empty. Trying to map over
    this string using `nixMap` while applying `escapeQuotes` causes the bash
    error as `eval echo "<PRIMOP>"` is invalid syntax.
    
    Explicitly checking if `$result' contains a value (do we have an
    attribute set?) and otherwise returning a warning and asking if $option
    exists fixes the problem.
    
    Fixes #48060
    Ma27 committed Oct 10, 2018
    Copy the full SHA
    76cc15a View commit details

Commits on Oct 16, 2018

  1. Copy the full SHA
    4ed7d82 View commit details

Commits on Oct 18, 2018

  1. Copy the full SHA
    3dd924b View commit details

Commits on Oct 26, 2018

  1. Copy the full SHA
    69936b5 View commit details

Commits on Nov 24, 2018

  1. Remane test-eval-release.sh to eval-release.sh

    Since this script can also be used for non testing purposes.
    nlewo committed Nov 24, 2018
    Copy the full SHA
    ea90e51 View commit details

Commits on Dec 15, 2018

  1. ansible-lint: 3.4.23 -> 3.5.1

    Semi-automatic update generated by
    https://github.com/ryantm/nixpkgs-update tools. This update was made
    based on information from
    https://repology.org/metapackage/python2.7-ansible-lint/versions
    r-ryantm committed Dec 15, 2018
    Copy the full SHA
    221762c View commit details
  2. osl: 1.9.10 -> 1.10.2

    Semi-automatic update generated by
    https://github.com/ryantm/nixpkgs-update tools. This update was made
    based on information from
    https://repology.org/metapackage/openshadinglanguage/versions
    r-ryantm committed Dec 15, 2018
    Copy the full SHA
    1ecbc12 View commit details
  3. openfortivpn: 1.7.1 -> 1.8.0

    Semi-automatic update generated by
    https://github.com/ryantm/nixpkgs-update tools. This update was made
    based on information from
    https://repology.org/metapackage/openfortivpn/versions
    r-ryantm committed Dec 15, 2018
    Copy the full SHA
    5b8d77d View commit details

Commits on Dec 22, 2018

  1. solr: 7.5.0 -> 7.6.0

    Semi-automatic update generated by
    https://github.com/ryantm/nixpkgs-update tools. This update was made
    based on information from
    https://repology.org/metapackage/solr/versions
    r-ryantm committed Dec 22, 2018
    Copy the full SHA
    4a9fcee View commit details

Commits on Dec 23, 2018

  1. rmlint: 2.6.1 -> 2.8.0

    The recipe now uses the default scons build phases.
    bachp committed Dec 23, 2018
    Copy the full SHA
    3b2506b View commit details
  2. rmlint: fix build without patch

    Mic92 committed Dec 23, 2018
    Copy the full SHA
    e7ad1fb View commit details

Commits on Dec 25, 2018

  1. Copy the full SHA
    8362452 View commit details

Commits on Jan 2, 2019

  1. Copy the full SHA
    420b83b View commit details

Commits on Jan 6, 2019

  1. doc: don't overwrite makeFlagsArray in the example

    Arrays like these should be appended to instead of overwritten in almost
    every case to avoid loosing the existing flags.
    LnL7 committed Jan 6, 2019
    Copy the full SHA
    e279767 View commit details
  2. Copy the full SHA
    7f76246 View commit details
  3. Copy the full SHA
    5605482 View commit details
  4. tmuxp: 1.4.2 -> 1.5.0a1

    marsam committed Jan 6, 2019
    Copy the full SHA
    154ace0 View commit details
  5. linux: add feature flag to indicate support for 32bit emulation

    Motivated by the need to warn users trying to build configurations that depend
    on being able to run 32bit apps on 64bit kernels.
    joachifm committed Jan 6, 2019
    Copy the full SHA
    6eea9ac View commit details
  6. Copy the full SHA
    ab070d1 View commit details

Commits on Jan 7, 2019

  1. nixos/containers: add bridge without address specified

    According to systemd-nspawn(1), --network-bridge implies --network-veth,
    and --port option is supported only when private networking is enabled.
    Fixes #52417.
    uvNikita committed Jan 7, 2019
    Copy the full SHA
    53013ea View commit details

Commits on Jan 8, 2019

  1. haskell.buildStackProject: use setup hook

    This makes things easier and hopefully fixes the arg too long issue.
    
    Fixes #49206.
    matthewbauer committed Jan 8, 2019
    Copy the full SHA
    0dabaca View commit details

Commits on Jan 9, 2019

  1. Copy the full SHA
    fd5a886 View commit details

Commits on Jan 10, 2019

  1. parity-beta: 2.2.5 -> 2.2.6

    akru committed Jan 10, 2019
    Copy the full SHA
    c6b162b View commit details
  2. parity: 2.1.10 -> 2.1.11

    akru committed Jan 10, 2019
    Copy the full SHA
    18387c4 View commit details

Commits on Jan 11, 2019

  1. ejabberd: 18.06 -> 18.12.1

    Izorkin committed Jan 11, 2019
    Copy the full SHA
    e680dd4 View commit details
  2. synergy: fix compilation on macOS

    cf-private is needed to build on macOS
    mroi committed Jan 11, 2019
    Copy the full SHA
    f84e353 View commit details
  3. ps_mem: 3.9 -> 3.12

    gnidorah committed Jan 11, 2019
    Copy the full SHA
    e0511ba View commit details
  4. kmsxx: 2018-09-10 -> 2018-10-23

    gnidorah committed Jan 11, 2019
    Copy the full SHA
    1f18bb6 View commit details
  5. qdirstat: 1.4 -> 1.5

    gnidorah committed Jan 11, 2019
    Copy the full SHA
    9ee99d9 View commit details

Commits on Jan 12, 2019

  1. mytetra: 1.43.27 -> 1.44.55

    gnidorah committed Jan 12, 2019
    Copy the full SHA
    ab7065b View commit details
  2. vk-messenger: 3.9.0 -> 4.0.1

    gnidorah committed Jan 12, 2019
    Copy the full SHA
    7ef94be View commit details
  3. franz: 4.0.4 -> 5.0.0-beta.19

    gnidorah committed Jan 12, 2019
    Copy the full SHA
    e107569 View commit details
  4. vkquake: 1.00.0 -> 1.01.0

    gnidorah committed Jan 12, 2019
    Copy the full SHA
    e0b64f5 View commit details
  5. openjk: 2017-08-11 -> 2018-09-17

    gnidorah committed Jan 12, 2019
    Copy the full SHA
    00349e3 View commit details
  6. xcbuild: provide migcom in toolchain

    This is needed to facilitate build of qt5.qtwebengine on darwin
    veprbl committed Jan 12, 2019
    Copy the full SHA
    7a6d18c View commit details
  7. qt511.qtwebengine: fix build on darwin

    Co-Authored-By: Josef Kemetmüller <josef.kemetmueller@gmail.com>
    veprbl and knedlsepp committed Jan 12, 2019
    Copy the full SHA
    45ab55e View commit details

Commits on Jan 13, 2019

  1. openmw-tes3mp: 0.6.0 -> 0.7.0-alpha

    gnidorah committed Jan 13, 2019
    Copy the full SHA
    6b79f05 View commit details
  2. openmpt123: 0.2.7025-beta20.1 -> 0.4.1

    gnidorah committed Jan 13, 2019
    Copy the full SHA
    f2b9162 View commit details
  3. bcc: 0.7.0 -> 0.8.0

    dtzWill committed Jan 13, 2019
    Copy the full SHA
    91f2eb7 View commit details
  4. Copy the full SHA
    d85777c View commit details
  5. Copy the full SHA
    4c84258 View commit details

Commits on Jan 14, 2019

  1. medfile: 3.3.1 -> 4.0.0

    Moredread committed Jan 14, 2019
    Copy the full SHA
    995833d View commit details
  2. Copy the full SHA
    da98284 View commit details
  3. Copy the full SHA
    1928102 View commit details
Showing 767 changed files with 11,877 additions and 6,328 deletions.
3 changes: 3 additions & 0 deletions doc/functions.xml
Original file line number Diff line number Diff line change
@@ -11,7 +11,10 @@
<xi:include href="functions/overrides.xml" />
<xi:include href="functions/generators.xml" />
<xi:include href="functions/debug.xml" />
<xi:include href="functions/fetchers.xml" />
<xi:include href="functions/trivial-builders.xml" />
<xi:include href="functions/fhs-environments.xml" />
<xi:include href="functions/shell.xml" />
<xi:include href="functions/dockertools.xml" />
<xi:include href="functions/prefer-remote-fetch.xml" />
</chapter>
206 changes: 206 additions & 0 deletions doc/functions/fetchers.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,206 @@
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="sec-pkgs-fetchers">
<title>Fetcher functions</title>

<para>
When using Nix, you will frequently need to download source code
and other files from the internet. Nixpkgs comes with a few helper
functions that allow you to fetch fixed-output derivations in a
structured way.
</para>

<para>
The two fetcher primitives are <function>fetchurl</function> and
<function>fetchzip</function>. Both of these have two required
arguments, a URL and a hash. The hash is typically
<literal>sha256</literal>, although many more hash algorithms are
supported. Nixpkgs contributors are currently recommended to use
<literal>sha256</literal>. This hash will be used by Nix to
identify your source. A typical usage of fetchurl is provided
below.
</para>

<programlisting><![CDATA[
{ stdenv, fetchurl }:
stdenv.mkDerivation {
name = "hello";
src = fetchurl {
url = "http://www.example.org/hello.tar.gz";
sha256 = "1111111111111111111111111111111111111111111111111111";
};
}
]]></programlisting>

<para>
The main difference between <function>fetchurl</function> and
<function>fetchzip</function> is in how they store the contents.
<function>fetchurl</function> will store the unaltered contents of
the URL within the Nix store. <function>fetchzip</function> on the
other hand will decompress the archive for you, making files and
directories directly accessible in the future.
<function>fetchzip</function> can only be used with archives.
Despite the name, <function>fetchzip</function> is not limited to
.zip files and can also be used with any tarball.
</para>

<para>
<function>fetchpatch</function> works very similarly to
<function>fetchurl</function> with the same arguments expected. It
expects patch files as a source and and performs normalization on
them before computing the checksum. For example it will remove
comments or other unstable parts that are sometimes added by
version control systems and can change over time.
</para>

<para>
Other fetcher functions allow you to add source code directly from
a VCS such as subversion or git. These are mostly straightforward
names based on the name of the command used with the VCS system.
Because they give you a working repository, they act most like
<function>fetchzip</function>.
</para>

<variablelist>
<varlistentry>
<term>
<literal>fetchsvn</literal>
</term>
<listitem>
<para>
Used with Subversion. Expects <literal>url</literal> to a
Subversion directory, <literal>rev</literal>, and
<literal>sha256</literal>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchgit</literal>
</term>
<listitem>
<para>
Used with Git. Expects <literal>url</literal> to a Git repo,
<literal>rev</literal>, and <literal>sha256</literal>.
<literal>rev</literal> in this case can be full the git commit
id (SHA1 hash) or a tag name like
<literal>refs/tags/v1.0</literal>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchfossil</literal>
</term>
<listitem>
<para>
Used with Fossil. Expects <literal>url</literal> to a Fossil
archive, <literal>rev</literal>, and <literal>sha256</literal>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchcvs</literal>
</term>
<listitem>
<para>
Used with CVS. Expects <literal>cvsRoot</literal>,
<literal>tag</literal>, and <literal>sha256</literal>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchhg</literal>
</term>
<listitem>
<para>
Used with Mercurial. Expects <literal>url</literal>,
<literal>rev</literal>, and <literal>sha256</literal>.
</para>
</listitem>
</varlistentry>
</variablelist>

<para>
A number of fetcher functions wrap part of
<function>fetchurl</function> and <function>fetchzip</function>.
They are mainly convenience functions intended for commonly used
destinations of source code in Nixpkgs. These wrapper fetchers are
listed below.
</para>

<variablelist>
<varlistentry>
<term>
<literal>fetchFromGitHub</literal>
</term>
<listitem>
<para>
<function>fetchFromGitHub</function> expects four arguments.
<literal>owner</literal> is a string corresponding to the
GitHub user or organization that controls this repository.
<literal>repo</literal> corresponds to the name of the
software repository. These are located at the top of every
GitHub HTML page as
<literal>owner</literal>/<literal>repo</literal>.
<literal>rev</literal> corresponds to the Git commit hash or
tag (e.g <literal>v1.0</literal>) that will be downloaded from
Git. Finally, <literal>sha256</literal> corresponds to the
hash of the extracted directory. Again, other hash algorithms
are also available but <literal>sha256</literal> is currently
preferred.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchFromGitLab</literal>
</term>
<listitem>
<para>
This is used with GitLab repositories. The arguments expected
are very similar to fetchFromGitHub above.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchFromBitbucket</literal>
</term>
<listitem>
<para>
This is used with BitBucket repositories. The arguments expected
are very similar to fetchFromGitHub above.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchFromSavannah</literal>
</term>
<listitem>
<para>
This is used with Savannah repositories. The arguments expected
are very similar to fetchFromGitHub above.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>fetchFromRepoOrCz</literal>
</term>
<listitem>
<para>
This is used with repo.or.cz repositories. The arguments
expected are very similar to fetchFromGitHub above.
</para>
</listitem>
</varlistentry>
</variablelist>


</section>
27 changes: 27 additions & 0 deletions doc/functions/prefer-remote-fetch.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/xinclude"
xml:id="sec-prefer-remote-fetch">
<title>prefer-remote-fetch overlay</title>

<para>
<function>prefer-remote-fetch</function> is an overlay that download sources
on remote builder. This is useful when the evaluating machine has a slow
upload while the builder can fetch faster directly from the source.
To use it, put the following snippet as a new overlay:
<programlisting>
self: super:
(super.prefer-remote-fetch self super)
</programlisting>

A full configuration example for that sets the overlay up for your own account,
could look like this

<programlisting>
$ mkdir ~/.config/nixpkgs/overlays/
$ cat &gt; ~/.config/nixpkgs/overlays/prefer-remote-fetch.nix &lt;&lt;EOF
self: super: super.prefer-remote-fetch self super
EOF
</programlisting>
</para>
</section>
124 changes: 124 additions & 0 deletions doc/functions/trivial-builders.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
<section xmlns="http://docbook.org/ns/docbook"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:xi="http://www.w3.org/2001/XInclude"
xml:id="sec-trivial-builders">
<title>Trivial builders</title>

<para>
Nixpkgs provides a couple of functions that help with building
derivations. The most important one,
<function>stdenv.mkDerivation</function>, has already been
documented above. The following functions wrap
<function>stdenv.mkDerivation</function>, making it easier to use
in certain cases.
</para>

<variablelist>
<varlistentry>
<term>
<literal>runCommand</literal>
</term>
<listitem>
<para>
This takes three arguments, <literal>name</literal>,
<literal>env</literal>, and <literal>buildCommand</literal>.
<literal>name</literal> is just the name that Nix will append
to the store path in the same way that
<literal>stdenv.mkDerivation</literal> uses its
<literal>name</literal> attribute. <literal>env</literal> is an
attribute set specifying environment variables that will be set
for this derivation. These attributes are then passed to the
wrapped <literal>stdenv.mkDerivation</literal>.
<literal>buildCommand</literal> specifies the commands that
will be run to create this derivation. Note that you will need
to create <literal>$out</literal> for Nix to register the
command as successful.
</para>
<para>
An example of using <literal>runCommand</literal> is provided
below.
</para>
<programlisting>
(import &lt;nixpkgs&gt; {}).runCommand "my-example" {} ''
echo My example command is running

mkdir $out

echo I can write data to the Nix store > $out/message

echo I can also run basic commands like:

echo ls
ls

echo whoami
whoami

echo date
date
''
</programlisting>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>runCommandCC</literal>
</term>
<listitem>
<para>
This works just like <literal>runCommand</literal>. The only
difference is that it also provides a C compiler in
<literal>buildCommand</literal>’s environment. To minimize your
dependencies, you should only use this if you are sure you will
need a C compiler as part of running your command.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>writeTextFile</literal>, <literal>writeText</literal>,
<literal>writeTextDir</literal>, <literal>writeScript</literal>,
<literal>writeScriptBin</literal>
</term>
<listitem>
<para>
These functions write <literal>text</literal> to the Nix store.
This is useful for creating scripts from Nix expressions.
<literal>writeTextFile</literal> takes an attribute set and
expects two arguments, <literal>name</literal> and
<literal>text</literal>. <literal>name</literal> corresponds to
the name used in the Nix store path. <literal>text</literal>
will be the contents of the file. You can also set
<literal>executable</literal> to true to make this file have
the executable bit set.
</para>
<para>
Many more commands wrap <literal>writeTextFile</literal>
including <literal>writeText</literal>,
<literal>writeTextDir</literal>,
<literal>writeScript</literal>, and
<literal>writeScriptBin</literal>. These are convenience
functions over <literal>writeTextFile</literal>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>
<literal>symlinkJoin</literal>
</term>
<listitem>
<para>
This can be used to put many derivations into the same directory
structure. It works by creating a new derivation and adding
symlinks to each of the paths listed. It expects two arguments,
<literal>name</literal>, and <literal>paths</literal>.
<literal>name</literal> is the name used in the Nix store path
for the created derivation. <literal>paths</literal> is a list of
paths that will be symlinked. These paths can be to Nix store
derivations or any other subdirectory contained within.
</para>
</listitem>
</varlistentry>
</variablelist>

</section>
Loading