Skip to content

Commit 3e77ba3

Browse files
author
Chris Polanski
committed
Merge remote-tracking branch 'origin/master'
2 parents 32599f2 + 04426f2 commit 3e77ba3

File tree

4 files changed

+21
-18
lines changed

4 files changed

+21
-18
lines changed

.scripts/publish_github_release.sh

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
REPO="$1"
44
TAG="$2"
5-
AUTH_TOKEN="$3"
5+
AUTH_TOKEN="$(<'/home/buildbot/.github_token')"
66

77
PRERELEASE=false
88
# RELEASEFILES=(debs/python-probe_basic_*.deb dist/probe_basic-*.tar.gz)
@@ -27,7 +27,8 @@ declare -a COMMIT_TYPES=(
2727
"REV:Reverted commits"
2828
)
2929

30-
LAST_RELEASE=$( git describe --abbrev=0 --tags `git rev-list --tags --skip=1 --max-count=1` )
30+
# shellcheck disable=SC2046
31+
LAST_RELEASE=$( git describe --abbrev=0 --tags "$(git rev-list --tags --skip=1 --max-count=1)" )
3132

3233
CREATE_CHANGELOG() {
3334

@@ -138,16 +139,16 @@ JSON=$(cat <<EOF
138139
}
139140
EOF
140141
)
141-
RESULT=`curl -s -w "\n%{http_code}\n" \
142+
RESULT=$(curl -s -w "\n%{http_code}\n" \
142143
-H "Authorization: token $AUTH_TOKEN" \
143144
-d "$JSON" \
144-
"https://api.github.com/repos/$REPO/releases"`
145-
if [ "`echo "$RESULT" | tail -1`" != "201" ]; then
145+
"https://api.github.com/repos/$REPO/releases")
146+
if [ "$(echo "$RESULT" | tail -1)" != "201" ]; then
146147
echo FAILED
147148
echo "$RESULT"
148149
exit 1
149150
fi
150-
RELEASEID=`echo "$RESULT" | sed -ne 's/^ "id": \(.*\),$/\1/p'`
151+
RELEASEID=$(echo "$RESULT" | sed -ne 's/^ "id": \(.*\),$/\1/p')
151152
if [[ -z "$RELEASEID" ]]; then
152153
echo FAILED
153154
echo "$RESULT"
@@ -160,16 +161,17 @@ for FILE in "${RELEASEFILES[@]}"; do
160161
echo "Warning: $FILE is not a file"
161162
continue
162163
fi
163-
FILESIZE=`stat -c '%s' "$FILE"`
164-
FILENAME=`basename $FILE`
164+
FILESIZE=$(stat -c '%s' "$FILE")
165+
# shellcheck disable=SC2006
166+
FILENAME=`basename "$FILE"`
165167
echo -n "Uploading $FILENAME... "
166-
RESULT=`curl -s -w "\n%{http_code}\n" \
168+
RESULT=$(curl -s -w "\n%{http_code}\n" \
167169
-H "Authorization: token $AUTH_TOKEN" \
168170
-H "Accept: application/vnd.github.manifold-preview" \
169171
-H "Content-Type: application/zip" \
170172
--data-binary "@$FILE" \
171-
"https://uploads.github.com/repos/$REPO/releases/$RELEASEID/assets?name=$FILENAME&size=$FILESIZE"`
172-
if [ "`echo "$RESULT" | tail -1`" != "201" ]; then
173+
"https://uploads.github.com/repos/$REPO/releases/$RELEASEID/assets?name=$FILENAME&size=$FILESIZE")
174+
if [ "$(echo "$RESULT" | tail -1)" != "201" ]; then
173175
echo FAILED
174176
echo "$RESULT"
175177
exit 1
@@ -184,12 +186,12 @@ JSON=$(cat <<EOF
184186
}
185187
EOF
186188
)
187-
RESULT=`curl -s -w "\n%{http_code}\n" \
189+
RESULT=$(curl -s -w "\n%{http_code}\n" \
188190
-X PATCH \
189191
-H "Authorization: token $AUTH_TOKEN" \
190192
-d "$JSON" \
191-
"https://api.github.com/repos/$REPO/releases/$RELEASEID"`
192-
if [ "`echo "$RESULT" | tail -1`" = "200" ]; then
193+
"https://api.github.com/repos/$REPO/releases/$RELEASEID")
194+
if [ "$(echo "$RESULT" | tail -1)" = "200" ]; then
193195
echo DONE
194196
else
195197
echo FAILED

docs_src/source/conf.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,16 @@
2424
# -- Project information -----------------------------------------------------
2525

2626
project = u'ProbeBasic'
27-
copyright = u'2019, Chris Polanski'
27+
copyright = u'2021, Chris Polanski'
2828
author = u'Chris Polanski'
2929

3030
# The short X.Y version.
3131
version = probe_basic.__version__.split('+')[0]
3232
# The full version, including alpha/beta/rc tags.
3333
release = probe_basic.__version__
3434

35+
rst_epilog = '.. |code version| replace:: ``%s``\n' % version
36+
rst_epilog += '.. |gh_bin_dl_url| replace:: https://github.com/kcjengr/probe_basic/releases/download/%s/ProbeBasic-Installer-%s.run' % (version, version)
3537

3638
# -- General configuration ---------------------------------------------------
3739

docs_src/source/quick_start.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,7 @@ On a terminal emulator run:
5454
Click the link below to download the ProbeBasicInstaller file. Once downloaded, find in its destination folder and right click and select properties. Select the Permissions Tab in the window that appears and check the box for "Allow this file to run as a program", see images below for reference. now double click the installer icon to begin the installation. Follow the installer instructions to install Probe Basic. Select all of the available items during initial installation. after installation probe basic should show up in the linuxcnc launch screen and you can select to create a desktop icon for it by selecting the check box to do so at the bottom of the page.
5555

5656

57-
https://github.com/kcjengr/probe_basic/releases/download/v0.3.4/ProbeBasic-Installer-0.3.4.run
58-
57+
Download Probe Basic Installer: |gh_bin_dl_url|
5958

6059

6160
.. image:: https://raw.githubusercontent.com/kcjengr/probe_basic/master/probe_basic/images/properties.png

pb-installer

0 commit comments

Comments
 (0)