status-react/scripts
Jakub Sokołowski 5903cf73fb
nix: stop passing watchman socket to Nix builds
This passing of Watchman socket was implemented in order to avoid this:
```
Error: EMFILE: too many open files, watch
    at FSEvent.FSWatcher._handle.onchange (node:internal/fs/watchers:204:21)
Emitted 'error' event on NodeWatcher instance at:
    at NodeWatcher.checkedEmitError (/private/tmp/nix-build-status-mobile-build-nightly-android.drv-0/node_modules/sane/src/node_watcher.js:143:12)
    at FSWatcher.emit (node:events:527:28)
    at FSEvent.FSWatcher._handle.onchange (node:internal/fs/watchers:210:12) {
  errno: -24,
  syscall: 'watch',
  code: 'EMFILE',
  filename: null
}
```
Which is caused by `jest-haste-map` used by `metro` starting to watch
the filesystem for file changes, which is pointless when doing a
one-off build using Nix.

But by setting `CI=true` we can make `metro` not start this waching of
files in the first place, removing the need for use of Watchman entirely.

By entirely dropping use of Watchman we also fix the following issue:
```
[cli] unable to talk to your watchman on /tmp/tmp-status-mobile-ABC/jenkins-state/sock! (Permission denied)
```
Which happens on multi-user Nix installations becuase the user that the
Nix build is executed as is not the same as the user that starts
Watchman and creates the socket file.

Issue: https://github.com/status-im/status-mobile/issues/13783

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2022-08-10 02:21:12 +02:00
..
hooks use 8 char commits SHAs for status-go diff link 2022-06-02 13:24:10 +02:00
version ci: use full timestamp for iOS CFBundleVersion 2020-01-23 19:42:19 +01:00
build-android.sh nix: stop passing watchman socket to Nix builds 2022-08-10 02:21:12 +02:00
colors.sh fdroid: add script that automates submissions 2021-10-13 12:13:38 +02:00
cut-release.sh Make cut release executable 2021-04-20 11:07:48 +02:00
encrypt-keychain.sh Add code-signing scripts and encrypted keychain 2018-09-11 12:10:33 +03:00
fdroid-pr.sh fdroid: add script that automates submissions 2021-10-13 12:13:38 +02:00
gen-random-passphrase.sh Add code-signing scripts and encrypted keychain 2018-09-11 12:10:33 +03:00
generate-keystore.sh nix: quote path uses to avoid issues with spaces 2022-07-27 16:11:28 +02:00
inotify_fix.sh cleanup of shell scripts 2020-02-24 19:31:55 +01:00
list-pull-requests.sh rename status-react to status-mobile 2022-07-17 14:46:16 +02:00
merge-pr.sh rename status-react to status-mobile 2022-07-17 14:46:16 +02:00
pr-statistics.sh rename status-react to status-mobile 2022-07-17 14:46:16 +02:00
run-coverage.sh add coverage test 2019-07-10 16:15:44 -04:00
sign-android.sh nix: quote path uses to avoid issues with spaces 2022-07-27 16:11:28 +02:00
start-react-native.sh use shadow-cljs 2020-04-30 15:43:46 +02:00
update-status-go.sh scripts/update-status-go: support commit SHA1 2022-03-28 17:44:16 +02:00
wait-for.sh narrow match with UID, print persistent matching processes 2019-11-30 14:47:06 +01:00