Commit graph

10846 commits

Author SHA1 Message Date
Eelco Dolstra
e3013543d3 Fix test 2017-12-07 01:07:07 +01:00
Eelco Dolstra
2df9cbeb47 Provide random access to cached NARs
E.g.

  $ time nix cat-store --store https://cache.nixos.org?local-nar-cache=/tmp/nars \
    /nix/store/b0w2hafndl09h64fhb86kw6bmhbmnpm1-blender-2.79/share/icons/hicolor/scalable/apps/blender.svg > /dev/null
  real    0m4.139s

  $ time nix cat-store --store https://cache.nixos.org?local-nar-cache=/tmp/nars \
    /nix/store/b0w2hafndl09h64fhb86kw6bmhbmnpm1-blender-2.79/share/icons/hicolor/scalable/apps/blender.svg > /dev/null
  real    0m0.024s

(Before, the second call took ~0.220s.)

This will use a NAR listing in
/tmp/nars/b0w2hafndl09h64fhb86kw6bmhbmnpm1.ls containing all metadata,
including the offsets of regular files inside the NAR. Thus, we don't
need to read the entire NAR. (We do read the entire listing, but
that's generally pretty small. We could use a SQLite DB by borrowing
some more code from nixos-channel-scripts/file-cache.hh.)

This is primarily useful when Hydra is serving files from an S3 binary
cache, in particular when you have giant NARs. E.g. we had some 12 GiB
NARs, so accessing individuals files was pretty slow.
2017-12-07 01:07:07 +01:00
Eelco Dolstra
338f29dbd4 nix ls-{nar,store}: Return offset of files in the NAR if known
E.g.

  $ nix ls-store --json --recursive --store https://cache.nixos.org /nix/store/b0w2hafndl09h64fhb86kw6bmhbmnpm1-blender-2.79 \
    | jq .entries.bin.entries.blender.narOffset
  400
2017-12-07 01:07:07 +01:00
Abseil Team
1b8dacca62 Changes imported from Abseil "staging" branch:
- 536d004b7e2d48927a5f82e71e9e3a0a9afedbc8 Change uint128 parameters to pass by value. by Alex Strelnikov <strel@google.com>

GitOrigin-RevId: 536d004b7e2d48927a5f82e71e9e3a0a9afedbc8
Change-Id: I9c5e73ce06c8423a27ec7bff2c4accc434e99cb2
2017-12-06 10:09:02 -05:00
Eelco Dolstra
ba334bd6f7
Merge pull request #1714 from LnL7/fix-ssh-store-nar
ssh-store: fix length when writing nar
2017-12-06 13:11:36 +01:00
Daiderd Jordan
2cb8aaa610
ssh-store: fix length when writing nar
This fixes nix copy and other things that use copyStorePath.
2017-12-06 11:41:08 +01:00
Shea Levy
11a7f8ce14
Merge branch 'fetchGit-fast-revision-update' 2017-12-05 11:16:39 -05:00
Eelco Dolstra
7f2c324ed1
Simplify build by including nlohmann/json.hpp 2017-12-04 17:11:36 +01:00
Abseil Team
f4f91f4216 Changes imported from Abseil "staging" branch:
- 1dde8a2a1868c32b32d62fba62eb37974f656948 Correct usage of CUnescape() in example. by Abseil Team <absl-team@google.com>

GitOrigin-RevId: 1dde8a2a1868c32b32d62fba62eb37974f656948
Change-Id: I5183a74a3c682ac55b2bf4be0d871375e1302aae
2017-12-04 09:58:18 -05:00
Eelco Dolstra
f1efb97075
Fix #1635. 2017-12-04 13:19:16 +01:00
Vincent Ambo
443e8ea995 feat(look-and-feel): Font-size based on host
My desktop is currently connected to a 4K screen and needs *slightly*
larger fonts for readability.
2017-12-03 18:37:28 +01:00
Abseil Team
8b727aa7ab Changes imported from Abseil "staging" branch:
- 5d8235b05f4ea2b33a138712f463a30b6ae75719 Incorporate PR https://github.com/abseil/abseil-cpp/pull/... by Xiaoyi Zhang <zhangxy@google.com>
  - f2bc653acdaa983aa2765693476c17cd1142d59b Run the StrSplit WorksWithLargeStrings test in all configs. by Matt Armstrong <marmstrong@google.com>
  - 43aed1ea7dffcd656e1916c2d5637650fc3a8de3 Incorporate PR https://github.com/abseil/abseil-cpp/pull/... by Xiaoyi Zhang <zhangxy@google.com>
  - d58511d60904c7090e44638339ba63b97ca96f1a Add a new simple Mutex lifetime test, to be extended later. by Greg Falcon <gfalcon@google.com>
  - db5c86c186c09ad57963bcbd2b6182f62bce8ed0 Actually use the exception in TestCheckerAtCountdown by Jon Cohen <cohenjon@google.com>
  - 29c01a72b62d9a4b90f9bd935e3575adbafd85ed Use factories instead of explicitly passing pointers to T... by Jon Cohen <cohenjon@google.com>
  - 54d5526ee6ab7784992845f6e6e2c7d48ba008a5 Fix uint128 ostream operator and improve ostream test. by Alex Strelnikov <strel@google.com>
  - 4e49abe7e569cf6bd0eae95ce2b2fe2faa051fa2 Fix documentation: strings::PairFormatter -> absl::PairFo... by Derek Mauro <dmauro@google.com>
  - 4044297f0e1a8a6c6ae3f781a65080e0d57c6751 Cut the memory used by the StrSplit WorksWithLargeStrings... by Jorg Brown <jorg@google.com>

GitOrigin-RevId: 5d8235b05f4ea2b33a138712f463a30b6ae75719
Change-Id: Ib6b6b0161c26e5326b53a126454754e33678eefc
2017-12-01 15:25:15 -05:00
zhangxy988
579f2879ac
Merge pull request #51 from behrenhoff/master
Fix CMakeLists.txt for ostringstream_test
2017-12-01 15:20:20 -05:00
zhangxy988
3562f9bb79
Merge pull request #55 from rongjiecomputer/master
MSVC fixes
2017-12-01 13:55:00 -05:00
Will Dietz
79f5c296c0 ignore "interrupted" exception in progress callback
Context/discusson:

https://github.com/NixOS/nix/issues/1692#issuecomment-348282301
2017-11-30 12:45:54 -06:00
Eelco Dolstra
cd74a55afc
Merge pull request #1704 from lheckemann/buildenv-eol-fix
Fix "Unexpected EOF reading a line" error
2017-11-29 15:27:57 +01:00
Linus Heckemann
f986a44980 Fix "Unexpected EOF reading a line" error
propagated-user-env-packages files in nixpkgs aren't all terminated by
newlines, as buildenv expected. Now it does not require a terminating
newline; note that this introduces a behaviour change: propagated user
env packages may now be spread across multiple lines. However, nix
1.11.x still expects them to be on a single line so this shouldn't be
used in nixpkgs for now.
2017-11-29 11:56:15 +00:00
Loo Rong Jie
e98380282f Add comments about warning flags 2017-11-29 08:37:53 +08:00
Eelco Dolstra
b52846ab5b
Show log tail when a remote build fails 2017-11-28 15:36:28 +01:00
Loo Rong Jie
79ae60ed97 MSVC fixes 2017-11-28 13:36:16 +08:00
Will Dietz
e50d7335bf doc: linenoise -> linenoise-ng 2017-11-27 18:36:20 -06:00
Will Dietz
964349e44d no "linenoiseFree" in linenoise-ng 2017-11-27 18:30:05 -06:00
Will Dietz
21f515724c replace vendored linenoise with linenoise-ng 2017-11-27 18:27:28 -06:00
Abseil Team
79610733f4 Changes imported from Abseil "staging" branch:
- 5c323578d5492e9fd6f24d049ed3f55c9dc136f8 Fix typo. by Abseil Team <absl-team@google.com>

GitOrigin-RevId: 5c323578d5492e9fd6f24d049ed3f55c9dc136f8
Change-Id: I75af467a356ac6037738aadbffe93cbcd7a1a747
2017-11-27 14:53:53 -05:00
Eelco Dolstra
3c470c97a1
Merge pull request #1699 from aszlig/fix-remote-build-log
build-remote: Fix missing log output
2017-11-27 13:59:51 +01:00
Wolf Behrenhoff
56d970fd0e Fix CMakeLists.txt for ostringstream_test
After commit 99b92c87 compiling with CMake stopped working. This commit fixes the issue.
2017-11-27 12:05:25 +01:00
Sergey Bogatyrets
9ff6fa817b Checking device arg too for defining dev instance (#129) 2017-11-26 11:10:19 -08:00
Matthew Garrett
dd6eb8767e Experimental RF code 2017-11-25 12:38:57 -08:00
Matthew Garrett
8bc67af6d7 Bump version 2017-11-25 12:21:48 -08:00
jazzina
b8cf8d073e Add support for SmartOne Alarm Kit 2017-11-25 12:20:46 -08:00
blapid
c85f6ac213 Cli venv support (#127)
* Update broadlink_cli

* Update broadlink_discovery
2017-11-25 12:14:34 -08:00
Michael Kaiser
71f320638e Fix protocol description (#125)
* Fix discovery packet format description

* fix MAC address offset

* Command packet format description

* Data description
2017-11-25 12:14:12 -08:00
Eugene Schava
2160488da2 sp2.get_energy 2017-11-25 12:11:05 -08:00
Eugene Schava
626b459b5b SP3S support (#117) 2017-11-25 12:08:58 -08:00
hackers365
1d7fba3d06 add honyar mp1 devtype 0x4ef7 2017-11-25 12:08:14 -08:00
Bengt Martensson
4f902342e7 New options for broadlink:cli: --convert and --durations. (#105)
Now takes several data arguments.
2017-11-25 12:06:12 -08:00
Julian Pastarmov
3d4789305e Only get temperature for devices that support it. (#102)
Calling check_temperature is only possible on the RM family of devices. The program used to crash if other types of devices were discovered (A1, MP1 etc.).
2017-11-25 12:04:10 -08:00
aszlig
6567ab95a0
build-remote: Fix missing log output
The storeUri variable in the build-remote hook is declared very much to
the start of the main function and a bunch of lines later, the same
variable gets checked via hasPrefix() but it gets assigned *after* that
check when the most suitable machine for the build was choosen.

So I guess this was just a typo in d16fd24973
and what we really want is to either checkd the prefix *after* assigning
storeUri or use bestMachine->storeUri directly.

I choose the latter, because the former could introduce even more
regressions if the try block where the variable gets assigned terminates
early.

Nevertheless, the reason why the log output didn't work is because
hasPrefix() checked for "ssh://" in front of storeUri, but if the
storeUri isn't set correctly (or at all), we don't get the log file
descriptor set up properly, leading to no log output.

I've adjusted the remote-builds test to include a regression test for
this, so that we can make sure we get a build output when using remote
builds.

In addition to that I've tested this with two of my build farms and the
build logs are emitted correctly again.

Signed-off-by: aszlig <aszlig@nix.build>
2017-11-25 01:34:18 +01:00
Eelco Dolstra
549c3706a5
nix path-info: Show URL of NARs in binary caches 2017-11-24 18:08:50 +01:00
Eelco Dolstra
90948a4e3a
nix-shell/nix-build: Support .drv files again
Fixes #1663.

Also handle '!<output-name>' (#1694).
2017-11-24 18:08:35 +01:00
Vincent Ambo
5b946a930c fix(lisp): Actually require lisp-setup in init.el 2017-11-24 16:45:12 +01:00
Shea Levy
eedbc4e06c
fetchGit: Ignore tarballTtl if rev is set and not in the repo.
Fixes #1697.
2017-11-24 06:09:24 -05:00
Vincent Ambo
ab11ea2176 feat(adho): Add BrewDog network 2017-11-24 09:28:15 +01:00
Vincent Ambo
f2403271ec feat(pkgs): Install SBCL & friends 2017-11-24 09:28:05 +01:00
Vincent Ambo
f93f03661b feat(functions): Add function to toggle final-newline behaviour 2017-11-22 23:55:21 +01:00
Vincent Ambo
4dce87d1e2 feat(lisp): Add basic Common Lisp settings 2017-11-22 23:55:01 +01:00
Vincent Ambo
ff7a9576b2 fix(kubernetes): Don't open overview in full-frame mode 2017-11-22 23:54:38 +01:00
Abseil Team
ae0cef35ae Changes imported from Abseil "staging" branch:
- 55c7dd8ad1570b4e6ce2103ed4d4b6becdea0d96 Remove line continuations which require CMake >= 3.0.  Al... by Jon Cohen <cohenjon@google.com>
  - ee66ad72a90259d6286bbfea7241ed976bb0f6fb Change absl::ParseDuration() to avoid double.  This allow... by Abseil Team <absl-team@google.com>
  - 89cf4cd49d8ff25cb3d29f06b2090029a2024e89 Internal change by Gennadiy Rozental <rogeeff@google.com>
  - cdb5879bf6aaf6bbd2ad1fe4a2b144bbdf0389c7 Internal change by Gennadiy Rozental <rogeeff@google.com>
  - e7b29d11bf24a63bf7637689ada8be7d619844fc Internal change by Gennadiy Rozental <rogeeff@google.com>
  - 2d4fc08d5d64a7760ad6230eccdb5b8014c2b0c3 Update the exception-safety testing framework. by Jon Cohen <cohenjon@google.com>

GitOrigin-RevId: 55c7dd8ad1570b4e6ce2103ed4d4b6becdea0d96
Change-Id: I6b560cbc4570dfc5aa9a2f90e84d69904df7eac5
2017-11-22 15:25:43 -05:00
Eelco Dolstra
0fc3e581e0
tests/run.sh: Fix /build conflict when building in a sandbox
https://hydra.nixos.org/build/64519355
2017-11-21 19:43:12 +01:00
Eelco Dolstra
d7da6c9ea9
fetchGit/fetchMercurial: Fix directory inclusion check
E.g. the existence of .gitignore would cause .git to be included.
2017-11-21 19:34:46 +01:00