nushell/scripts
Skyler Hawthorne 9a4dad6ca1
Fix unit tests on Android (#10224)
# Description

* The path to the binaries for tests is slightly incorrect. It is
missing the build target when it is set with the `CARGO_BUILD_TARGET`
environment variable. For example, when `CARGO_BUILD_TARGET` is set to
`aarch64-linux-android`, the path to the `nu` binary is:

  `./target/aarch64-linux-android/debug/nu`

  rather than

  `./target/debug/nu`

This is common on Termux since the default target that rustc detects can
cause problems on some projects, such as [python's `cryptography`
package](https://github.com/pyca/cryptography/issues/7248).
  
This technically isn't a problem specific to Android, but is more likely
to happen on Android due to the latter.
* Additionally, the existing variable named `NUSHELL_CARGO_TARGET` is in
fact the profile, not the build target, so this was renamed to
`NUSHELL_CARGO_PROFILE`. This change is included because without the
rename, the build system would be using `CARGO_BUILD_TARGET` for the
build target and `NUSHELL_CARGO_TARGET` for the build profile, which is
confusing.
* `std path add` tests were missing `android` test

# User-Facing Changes

For those who would like to build nushell on Termux, the unit tests will
pass now.
2023-09-05 20:17:34 +12:00
..
build-all-maclin.sh update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00
build-all-windows.cmd update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00
build-all.nu update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00
build.rs
coverage-local.nu Fix unit tests on Android (#10224) 2023-09-05 20:17:34 +12:00
coverage-local.sh Fix unit tests on Android (#10224) 2023-09-05 20:17:34 +12:00
install-all.ps1 update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00
install-all.sh update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00
README.md
register-plugins.nu add a new toolkit install command with --features support (#9288) 2023-05-26 11:22:34 +02:00
test_virtualenv.nu Simplify virtualenv testing (#10035) 2023-08-20 17:00:59 +03:00
uninstall-all.sh update install/build scripts to include --locked (#10086) 2023-08-21 12:42:42 -05:00

run the scripts

Note


the following table must be read as follows:

  • an x means it works
  • a ? means no data available

.nu scripts must be run as nu .../foo.nu
.sh scripts must be run as ./.../foo.sh
.ps1 scripts must be run as powershell .../foo.ps1

let's say a script is called foo

  • an x in the ./scripts column means foo can be run from ./scripts
  • an x in the root column means foo can be run from the root of nushell
  • an x in the anywhere column means foo can be run from anywhere!
script ./scripts/ root anywhere
build-all-maclin.sh x x x
build-all-windows.cmd ? x ?
build-all.nu x x x
coverage-local.nu x x x
coverage-local.sh x x x
install-all.ps1 ? x ?
install-all.sh x x x
register-plugins.nu x x x
uninstall-all.sh x x x