Commit graph

52 commits

Author SHA1 Message Date
Josef Kemetmueller 7116da8018 Python docs: Add example for overlays 2017-06-10 12:18:10 +02:00
Dmitry Vyal 0f86046db5 user-local config.nix path fixed in docs 2017-05-27 13:38:15 +03:00
Frederik Rietdijk ef4442e827 Python: replace requests2 with requests tree-wide
See f63eb58573

The `requests2` attribute now throws an error informing that `requests`
should be used instead.
2017-05-07 12:56:09 +02:00
Frederik Rietdijk 8d491ec6c6 Python docs: Python 2.x namespace packages may collide when using .withPackages 2017-04-18 09:05:00 +02:00
Frederik Rietdijk ce6cd33c65 Python docs: small fixes 2017-03-22 12:55:11 +01:00
Joachim Schiele 91debcb482 Update python.md (#23669)
* Update python.md

this makes it clear how to alter `attributes` by using `packageOverrides`

* Update python.md

* Update python.md

* Update python.md

* Update python.md

* Update python.md

* Update python.md
2017-03-21 00:06:51 +01:00
Alexey Muranov 34afc31c49
doc: fix code highlighting, use valid Nix syntax
Fix code syntax highlighting by specifying language in every code block
and adding some context to Nix code blocks to make them valid
expressions.  Use the same markup style for all code blocks.  Reformat
some code blocks.

fixes #23535
2017-03-06 17:49:07 +01:00
Alexey Muranov 97c9ed0ba1
doc: cleanup whitespace in python.md 2017-03-06 17:48:55 +01:00
Frederik Rietdijk 37704e90e2 Python: explain deterministic build in docs 2017-02-26 14:51:26 +01:00
Frederik Rietdijk 026cfee6b0 Docs: update Python contributing guidelines 2017-02-22 13:38:29 +01:00
Domen Kožar 220adbb039
docs: fix link for python 2017-02-01 21:32:06 +01:00
Jörg Thalheim a9495b3066 Merge pull request #21837 from Azulinho/python-docs_add_virtualenv_and_nixshell_example
python docs: add an example for a virtualenv and pip through nix-shell
2017-01-18 08:37:13 +01:00
Nicolas B. Pierron f5dfe78a1e Add overlays mechanism to Nixpkgs.
This patch add a new argument to Nixpkgs default expression named "overlays".

By default, the value of the argument is either taken from the environment variable `NIXPKGS_OVERLAYS`,
or from the directory `~/.nixpkgs/overlays/`.  If the environment variable does not name a valid directory
then this mechanism would fallback on the home directory.  If the home directory does not exists it will
fallback on an empty list of overlays.

The overlays directory should contain the list of extra Nixpkgs stages which would be used to extend the
content of Nixpkgs, with additional set of packages.  The overlays, i-e directory, files, symbolic links
are used in alphabetical order.

The simplest overlay which extends Nixpkgs with nothing looks like:

```nix
self: super: {
}
```

More refined overlays can use `super` as the basis for building new packages, and `self` as a way to query
the final result of the fix-point.

An example of overlay which extends Nixpkgs with a small set of packages can be found at:
  https://github.com/nbp/nixpkgs-mozilla/blob/nixpkgs-overlay/moz-overlay.nix

To use this file, checkout the repository and add a symbolic link to
the `moz-overlay.nix` file in `~/.nixpkgs/overlays` directory.
2017-01-16 01:17:33 +01:00
Azul 58613a7eed python docs: update block according to code review 2017-01-12 16:59:27 +00:00
Azul aa9a9dd1b4 python docs: add an example for a virtualenv and pip through nix-shell 2017-01-12 16:00:50 +00:00
Frederik Rietdijk e0d1691ba3 Docs Python: fix examples and links 2016-12-21 15:45:39 +01:00
Frederik Rietdijk 42bad32e13 buildPythonPackage: refactor 2016-12-05 10:29:22 +01:00
Frederik Rietdijk 3d59b82925 DOCS: update Python docs to reflect fixed-point combinator 2016-12-05 09:45:11 +01:00
Frederik Rietdijk 374ac13a6e Docs: fix Python docs 2016-12-04 10:17:33 +01:00
Frederik Rietdijk 9cdfb33401 Docs: improve Python expressions
as it contained several mistakes and was just messy.
2016-11-08 12:44:49 +01:00
Frederik Rietdijk 8fa308126f Python: update docs with change in default interpreter version 2016-10-18 23:16:05 +02:00
Frederik Rietdijk 107c035bf0 Python: remove pythonSmall
In #19309 a separate output for tkinter was added.

Several dependencies of Python depend indirectly on Python. We have the
following two paths:
```
‘python-2.7.12’ - ‘tk-8.6.6’ - ‘libXft-2.3.2’ - ‘libXrender-0.9.10’ -
‘libX11-1.6.4’ - ‘libxcb-1.12’ - ‘libxslt-1.1.29’- ‘libxml2-2.9.4’ -
‘python-2.7.12’

‘python-2.7.12’ - ‘tk-8.6.6’ - ‘libXft-2.3.2’ - ‘fontconfig-2.12.1’ -
‘dejavu-fonts-2.37’ - ‘fontforge-20160404’ - ‘python-2.7.12’
```
Because only `tkinter` needs this, I added
```
pythonSmall = python.override {x11Support = false;};
```
to break the infinite recursion. We also still have the output
`tkinter`.

However, we might as well build without x11Support by default. Then we build with x11Support as well so we get the tkinter module and put that in a separate package.
2016-10-16 14:31:26 +02:00
Frederik Rietdijk 1e544b2993 pythonPackages.tkinter: use this instead of the output python.tkinter 2016-10-13 10:38:21 +02:00
Frederik Rietdijk d3766b2601 Python: update docs separate output tkinter 2016-10-10 10:33:24 +02:00
Frederik Rietdijk 4f6b6f1472 pythonPackages: use mkPythonDerivation 2016-09-01 16:16:31 +02:00
Frederik Rietdijk 3e05cce97c Python: separate buildPythonPackage into two functions
1. mkDerivation which is used when the source is without setup.py and
not a wheel
2. buildPythonPackage which is used as before and calls mkDerivation
2016-09-01 16:16:31 +02:00
Frederik Rietdijk b080748d42 Python: move python-modules/generic to interpreter folder 2016-09-01 16:16:31 +02:00
Frederik Rietdijk 850e6287c5 Doc: improve python bdist_wheel fix 2016-08-30 17:16:49 +02:00
Frederik Rietdijk 95021f061a Doc: fix python override examples 2016-08-30 17:06:44 +02:00
obadz 0e8d2725dc Merge branch 'master' into staging 2016-08-23 18:50:06 +01:00
Tuomas Tynkkynen 9551d400b2 python manual: Fix 'fftw*' output references in example 2016-08-23 03:20:21 +03:00
obadz 24a9183f90 Merge branch 'hardened-stdenv' into staging
Closes #12895

Amazing work by @globin & @fpletz getting hardened compiler flags by
enabled default on the whole package set
2016-08-22 01:19:35 +01:00
Nikolay Amiantov 01624e1ac2 wrapPythonProgram: use site.addsitedir instead of PYTHONPATH 2016-08-20 00:42:49 +03:00
Robin Gloster 33e1c78ae3 Merge remote-tracking branch 'upstream/master' into hardened-stdenv 2016-08-16 07:54:01 +00:00
Frederik Rietdijk 888efed972 Doc: fix python examples 2016-08-16 09:47:13 +02:00
Franz Pletz bd4490e277 Merge branch 'master' into hardened-stdenv 2016-08-13 16:59:55 +02:00
Frederik Rietdijk 6f1551d597 Doc: how to create a Python wheel 2016-08-13 14:19:33 +02:00
Robin Gloster 5185bc1773 Merge remote-tracking branch 'upstream/master' into hardened-stdenv 2016-07-15 14:41:01 +00:00
Frederik Rietdijk 1c0af40757 Doc: how to install a Python environment
See https://github.com/NixOS/nixpkgs/issues/10597.
2016-07-01 14:30:18 +02:00
Domen Kožar 3ea8068181 buildPythonPackage: be able to disable package conflict check 2016-06-16 11:49:19 +01:00
Robin Gloster 2d382f3d98 Merge remote-tracking branch 'upstream/master' into hardened-stdenv 2016-05-30 19:39:34 +00:00
Benno Fünfstück 5e0acb90d6 doc/python: fix conversion errors in example code 2016-05-29 16:44:54 +02:00
Benno Fünfstück bad156a0d5 doc/python: replace buildEnv usage by withPackages 2016-05-29 16:30:29 +02:00
Benno Fünfstück 3bdf167619 doc/python: document python.withPackages 2016-05-29 16:08:27 +02:00
Franz Pletz f8d481754c
Merge remote-tracking branch 'origin/master' into hardened-stdenv 2016-05-18 17:10:02 +02:00
Frederik Rietdijk 303e976245 Python: allow installing wheels
By passing `format="wheel"` it is now possible to install a wheel.
It's not recommended, but it can be useful.
2016-05-09 13:17:42 +02:00
Robin Gloster c92bca56f8 Merge remote-tracking branch 'upstream/master' into hardened-stdenv 2016-05-02 22:58:02 +00:00
Frederik Rietdijk d5e6a4494a Python: use PyPI mirror (#15001)
* mirrors: add pypi

* Python: Use pypi mirror for all PyPI packages
2016-04-26 13:38:03 +01:00
Robin Gloster a73a28de7b fix grammar errors 2016-04-06 16:16:23 +00:00
Frederik Rietdijk 4c1525c1f8 Documentation: rewrite Python
- Rewrite current documentation
- Add introduction/tutorial
- Convert to markdown
2016-03-12 15:44:02 -05:00