Apply tabs project-wide
This commit is contained in:
parent
33f8b60e46
commit
23d794ed7e
|
@ -1,25 +1,17 @@
|
|||
root = true
|
||||
|
||||
[*]
|
||||
indent_style = space
|
||||
indent_style = tab
|
||||
indent_size = 4
|
||||
end_of_line = lf
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
[lib/**/*.rs]
|
||||
indent_style = tab
|
||||
|
||||
[*.toml]
|
||||
indent_size = 2
|
||||
|
||||
[*.yml]
|
||||
indent_size = 2
|
||||
|
||||
[*.wat]
|
||||
indent_size = 2
|
||||
|
||||
[*.md]
|
||||
[*.{md,ronn}]
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
|
||||
[*.{cff,yml}]
|
||||
indent_size = 2
|
||||
indent_style = space
|
||||
indent_size = 3
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
[workspace]
|
||||
members = [
|
||||
"lib",
|
||||
"cli",
|
||||
"lib",
|
||||
"cli",
|
||||
]
|
||||
|
||||
[profile.release]
|
||||
|
|
45
bin/sign
45
bin/sign
|
@ -3,42 +3,41 @@
|
|||
set -euo pipefail
|
||||
|
||||
if ! which rsign >/dev/null; then
|
||||
echo "Requires rsign2 tool: $ cargo install rsign2"
|
||||
exit 2
|
||||
echo "Requires rsign2 tool: $ cargo install rsign2"
|
||||
exit 2
|
||||
fi
|
||||
|
||||
missing=""
|
||||
for f in {B3,SHA512}SUMS{,.auto.minisig}; do
|
||||
[[ ! -f "$f" ]] && missing="$missing $f"
|
||||
[[ ! -f "$f" ]] && missing="$missing $f"
|
||||
done
|
||||
|
||||
if [[ ! -z "$missing" ]]; then
|
||||
echo "Usage: bin/sign [rsign options...]"
|
||||
echo "You must first download the relevant sums and minisig files."
|
||||
echo "Missing: $missing"
|
||||
exit 1
|
||||
echo "Usage: bin/sign [rsign options...]"
|
||||
echo "You must first download the relevant sums and minisig files."
|
||||
echo "Missing: $missing"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
sigs=""
|
||||
for algo in B3 SHA512; do
|
||||
echo "Verifying ${algo}SUMS.auto.minisig:"
|
||||
rsign verify \
|
||||
-p "$(dirname $BASH_SOURCE)/../.github/workflows/release.pub" \
|
||||
-x "${algo}SUMS.auto.minisig" \
|
||||
"${algo}SUMS"
|
||||
|
||||
echo "Verifying ${algo}SUMS.auto.minisig:"
|
||||
rsign verify \
|
||||
-p "$(dirname $BASH_SOURCE)/../.github/workflows/release.pub" \
|
||||
-x "${algo}SUMS.auto.minisig" \
|
||||
"${algo}SUMS"
|
||||
version=$(grep -m1 -oP 'watchexec-[\d.]+' "${algo}SUMS" | cut -d- -f3)
|
||||
ownsig="${algo}SUMS.$(whoami).minisig"
|
||||
sigs="$sigs $ownsig"
|
||||
|
||||
version=$(grep -m1 -oP 'watchexec-[\d.]+' "${algo}SUMS" | cut -d- -f3)
|
||||
ownsig="${algo}SUMS.$(whoami).minisig"
|
||||
sigs="$sigs $ownsig"
|
||||
|
||||
echo "Signing ${algo}SUMS with your key to $ownsig:"
|
||||
rsign sign \
|
||||
-t "watchexec $version signed by maintainer: $(whoami)" \
|
||||
-c 'see README.md for signing information' \
|
||||
-x "$ownsig" \
|
||||
$@ \
|
||||
"${algo}SUMS"
|
||||
echo "Signing ${algo}SUMS with your key to $ownsig:"
|
||||
rsign sign \
|
||||
-t "watchexec $version signed by maintainer: $(whoami)" \
|
||||
-c 'see README.md for signing information' \
|
||||
-x "$ownsig" \
|
||||
$@ \
|
||||
"${algo}SUMS"
|
||||
done
|
||||
|
||||
echo "Done; please upload $sigs to Github release $version!"
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
fn main() {
|
||||
embed_resource::compile("watchexec-manifest.rc");
|
||||
embed_resource::compile("watchexec-manifest.rc");
|
||||
}
|
||||
|
|
|
@ -5,20 +5,20 @@ use insta::assert_snapshot;
|
|||
|
||||
#[test]
|
||||
fn help() {
|
||||
let output = Command::cargo_bin("watchexec")
|
||||
.unwrap()
|
||||
.arg("--help")
|
||||
.output()
|
||||
.unwrap();
|
||||
let output = Command::cargo_bin("watchexec")
|
||||
.unwrap()
|
||||
.arg("--help")
|
||||
.output()
|
||||
.unwrap();
|
||||
|
||||
assert!(output.status.success(), "--help returns 0");
|
||||
assert_eq!(output.stderr, Vec::<u8>::new(), "--help stderr is empty");
|
||||
assert_snapshot!(
|
||||
if cfg!(windows) {
|
||||
"help_windows"
|
||||
} else {
|
||||
"help_unix"
|
||||
},
|
||||
String::from_utf8(output.stdout).unwrap()
|
||||
);
|
||||
assert!(output.status.success(), "--help returns 0");
|
||||
assert_eq!(output.stderr, Vec::<u8>::new(), "--help stderr is empty");
|
||||
assert_snapshot!(
|
||||
if cfg!(windows) {
|
||||
"help_windows"
|
||||
} else {
|
||||
"help_unix"
|
||||
},
|
||||
String::from_utf8(output.stdout).unwrap()
|
||||
);
|
||||
}
|
||||
|
|
|
@ -1,41 +1,41 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Watchexec.Cli.watchexec"
|
||||
version="1.17.1.0"
|
||||
/>
|
||||
<assemblyIdentity
|
||||
type="win32"
|
||||
name="Watchexec.Cli.watchexec"
|
||||
version="1.17.1.0"
|
||||
/>
|
||||
|
||||
<trustInfo>
|
||||
<security>
|
||||
<!--
|
||||
UAC settings:
|
||||
- app should run at same integrity level as calling process
|
||||
- app does not need to manipulate windows belonging to
|
||||
higher-integrity-level processes
|
||||
-->
|
||||
<requestedPrivileges>
|
||||
<requestedExecutionLevel level="asInvoker" uiAccess="false"/>
|
||||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
<trustInfo>
|
||||
<security>
|
||||
<!--
|
||||
UAC settings:
|
||||
- app should run at same integrity level as calling process
|
||||
- app does not need to manipulate windows belonging to
|
||||
higher-integrity-level processes
|
||||
-->
|
||||
<requestedPrivileges>
|
||||
<requestedExecutionLevel level="asInvoker" uiAccess="false"/>
|
||||
</requestedPrivileges>
|
||||
</security>
|
||||
</trustInfo>
|
||||
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
<!-- Windows 8.1 -->
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
|
||||
<!-- Windows 8 -->
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
|
||||
</application>
|
||||
</compatibility>
|
||||
<compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
|
||||
<application>
|
||||
<!-- Windows 10 -->
|
||||
<supportedOS Id="{8e0f7a12-bfb3-4fe8-b9a5-48fd50a15a9a}"/>
|
||||
<!-- Windows 8.1 -->
|
||||
<supportedOS Id="{1f676c76-80e1-4239-95bb-83d0f6d0da78}"/>
|
||||
<!-- Windows 8 -->
|
||||
<supportedOS Id="{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}"/>
|
||||
</application>
|
||||
</compatibility>
|
||||
|
||||
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<windowsSettings xmlns:ws="http://schemas.microsoft.com/SMI/2020/WindowsSettings">
|
||||
<ws:longPathAware xmlns:ws="http://schemas.microsoft.com/SMI/2016/WindowsSettings">true</ws:longPathAware>
|
||||
<ws:activeCodePage xmlns:ws="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</ws:activeCodePage>
|
||||
<ws:heapType xmlns:ws="http://schemas.microsoft.com/SMI/2020/WindowsSettings">SegmentHeap</ws:heapType>
|
||||
</windowsSettings>
|
||||
</application>
|
||||
<application xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<windowsSettings xmlns:ws="http://schemas.microsoft.com/SMI/2020/WindowsSettings">
|
||||
<ws:longPathAware xmlns:ws="http://schemas.microsoft.com/SMI/2016/WindowsSettings">true</ws:longPathAware>
|
||||
<ws:activeCodePage xmlns:ws="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</ws:activeCodePage>
|
||||
<ws:heapType xmlns:ws="http://schemas.microsoft.com/SMI/2020/WindowsSettings">SegmentHeap</ws:heapType>
|
||||
</windowsSettings>
|
||||
</application>
|
||||
</assembly>
|
||||
|
|
|
@ -9,31 +9,31 @@ local -a _comp_priv_prefix
|
|||
cmd="$words[1]"
|
||||
|
||||
args=(
|
||||
'(-c --clear)'{-c,--clear}'[Clear screen before executing command]'
|
||||
'(-h --help)'{-h,--help}'[Prints help information]'
|
||||
'--shell=[Change the wrapping shell, or set to none to disable]'
|
||||
'--no-shell[Deprecated, use --shell=none]'
|
||||
'-n[Shorthand for --shell=none]'
|
||||
'--no-environment[Do not set WATCHEXEC_*_PATH environment variables for command]'
|
||||
'--no-meta[Ignore metadata changes]'
|
||||
'(-p --postpone)'{-p,--postpone}'[Wait until first change to execute command]'
|
||||
'(-r --restart)'{-r,--restart}'[Restart the process if it''s still running]'
|
||||
'(-W --watch-when-idle)'{-W,--watch-when-idle}'[Ignore events while the command is still running]'
|
||||
'(-V --version)'{-V,--version}'[Prints version information]'
|
||||
'(-v --verbose)'{-v,--verbose}'[Print debugging messages to stderr]'
|
||||
'--changes-only[Print changed paths to stderr for pattern debugging]'
|
||||
'(-d --debounce)'{-d+,--debounce=}'[Set the timeout between detected change and command execution, defaults to 100ms]:milliseconds'
|
||||
'(-e --exts)'{-e+,--exts=}'[Comma-separated list of file extensions to watch (js,css,html)]:extensions'
|
||||
'(-f --filter)'{-f+,--filter=}'[Ignore all modifications except those matching the pattern]:pattern'
|
||||
'(-i --ignore)'{-i+,--ignore=}'[Ignore modifications to paths matching the pattern]:pattern'
|
||||
'(-w --watch)'{-w+,--watch=}'[Watch a specific directory]:path:_path_files -/'
|
||||
'(-s --signal)'{-s+,--signal=}'[Send signal to process upon changes, e.g. SIGHUP]:signal'
|
||||
'--force-poll=[Forces polling mode]:interval'
|
||||
'--no-ignore[Skip auto-loading of ignore files (.gitignore, .ignore, etc.) for filtering]'
|
||||
'--no-default-ignore[Skip auto-ignoring of commonly ignored globs]'
|
||||
'--no-vcs-ignore[Skip auto-loading of .gitignore files for filtering]'
|
||||
'(-)1:command: _command_names -e'
|
||||
'*::arguments:{ _comp_priv_prefix=( $cmd -n ${(kv)opt_args[-u]} ) ; _normal }'
|
||||
'(-c --clear)'{-c,--clear}'[Clear screen before executing command]'
|
||||
'(-h --help)'{-h,--help}'[Prints help information]'
|
||||
'--shell=[Change the wrapping shell, or set to none to disable]'
|
||||
'--no-shell[Deprecated, use --shell=none]'
|
||||
'-n[Shorthand for --shell=none]'
|
||||
'--no-environment[Do not set WATCHEXEC_*_PATH environment variables for command]'
|
||||
'--no-meta[Ignore metadata changes]'
|
||||
'(-p --postpone)'{-p,--postpone}'[Wait until first change to execute command]'
|
||||
'(-r --restart)'{-r,--restart}'[Restart the process if it''s still running]'
|
||||
'(-W --watch-when-idle)'{-W,--watch-when-idle}'[Ignore events while the command is still running]'
|
||||
'(-V --version)'{-V,--version}'[Prints version information]'
|
||||
'(-v --verbose)'{-v,--verbose}'[Print debugging messages to stderr]'
|
||||
'--changes-only[Print changed paths to stderr for pattern debugging]'
|
||||
'(-d --debounce)'{-d+,--debounce=}'[Set the timeout between detected change and command execution, defaults to 100ms]:milliseconds'
|
||||
'(-e --exts)'{-e+,--exts=}'[Comma-separated list of file extensions to watch (js,css,html)]:extensions'
|
||||
'(-f --filter)'{-f+,--filter=}'[Ignore all modifications except those matching the pattern]:pattern'
|
||||
'(-i --ignore)'{-i+,--ignore=}'[Ignore modifications to paths matching the pattern]:pattern'
|
||||
'(-w --watch)'{-w+,--watch=}'[Watch a specific directory]:path:_path_files -/'
|
||||
'(-s --signal)'{-s+,--signal=}'[Send signal to process upon changes, e.g. SIGHUP]:signal'
|
||||
'--force-poll=[Forces polling mode]:interval'
|
||||
'--no-ignore[Skip auto-loading of ignore files (.gitignore, .ignore, etc.) for filtering]'
|
||||
'--no-default-ignore[Skip auto-ignoring of commonly ignored globs]'
|
||||
'--no-vcs-ignore[Skip auto-loading of .gitignore files for filtering]'
|
||||
'(-)1:command: _command_names -e'
|
||||
'*::arguments:{ _comp_priv_prefix=( $cmd -n ${(kv)opt_args[-u]} ) ; _normal }'
|
||||
)
|
||||
|
||||
_arguments -s -S $args
|
||||
|
|
Loading…
Reference in New Issue