Skip to content

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed
 

‎x

+4-1
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,12 @@
77

88
set -eu
99

10+
# syntax check
11+
sh -n $0
12+
1013
realpath() {
1114
if [ -d "$1" ]; then
12-
CDPATH='' command cd "$1" && pwd -P
15+
CDPATH='' command cd "$1" && pwd -P
1316
else
1417
echo "$(realpath "$(dirname "$1")")/$(basename "$1")"
1518
fi

‎x.ps1

+5
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22

33
# See ./x for why these scripts exist.
44

5+
$ErrorActionPreference = "Stop"
6+
7+
# syntax check
8+
Get-Command -syntax ${PSCommandPath}
9+
510
$xpy = Join-Path $PSScriptRoot x.py
611
# Start-Process for some reason splits arguments on spaces. (Isn't powershell supposed to be simpler than bash?)
712
# Double-quote all the arguments so it doesn't do that.

0 commit comments

Comments
 (0)
Please sign in to comment.