Check-in [60c3d05d74]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Bump version to 3.0.1; tagrelease to create tarball and tidy file testing
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256:60c3d05d74f17b61122bccf935491444db9b906bed63177c8ab05e274e5e25a8
User & Date: kjnash 2018-06-23 02:07:05
Context
2018-06-25
21:28
Revised API for Dragger/Dropper/Helper Snit objects. Add newlines to some i18n strings, and -justify to their label. Document the Dragger/Dropper/Helper Snit objects. Update version number and names BWidget/Snit in documentation. check-in: c631840207 user: kjnash tags: trunk
2018-06-23
02:07
Bump version to 3.0.1; tagrelease to create tarball and tidy file testing check-in: 60c3d05d74 user: kjnash tags: trunk
01:32
append fossil push to tagrelease check-in: b05c20c290 user: kjnash tags: trunk
Changes

Changes to SlabVersion.txt.

1
3.0.0
|
1
3.0.1

Changes to tagrelease.

1
2
3
4
5
6
7
8
9
10







11
12
13
14
15
16
17
..
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
..
44
45
46
47
48
49
50






51
52
53
54
55
56
57
58
59
60
61
62
...
123
124
125
126
127
128
129
130




131
132
133
134
135
136
137
...
183
184
185
186
187
188
189
190






#!/bin/bash

# ------------------------------------------------------------------------------
# Script for creating a release, with a branch and a tag, from the current
# checkout.
#
# - The script is useful when a repository holds files with a (fixed) default
#   version number (here, "999"), but tagged releases have a different
#   (and variable) version number.
# ------------------------------------------------------------------------------









# ------------------------------------------------------------------------------
# For testing.
# ------------------------------------------------------------------------------

# Commands that change anything are preceded with $ECHO.
................................................................................
ECHO=


# ------------------------------------------------------------------------------
# Set constants, define functions.
# ------------------------------------------------------------------------------

VERFILE="SlabVersion.txt"
BASENAME=$(basename $0)

die() {
    if [ $# -ne 0 ]
    then
        echo "$@" >&2
    fi
................................................................................
    exit 1
}

checkout() {
    fossil info|grep '^checkout:'| sed -e 's/^checkout:[[:space:]]*//; s/[[:space:]].*$//'
}








# ------------------------------------------------------------------------------
# CHECK the command arguments, version file, and version,
# user consent, file clobber, pre-existence of any files with the new version,
# pre-existence of directory
# ------------------------------------------------------------------------------


# CHECK command arguments:

test "$#" -lt 2 || usage

................................................................................
        die
    fi
else
    echo
fi

NEWDIR="../${TAGLABEL}"
test -e "$NEWDIR" -o -L "$NEWDIR" && die "a file \"$NEWDIR\" already exists."






# CHECK that the operation will not clobber existing files:

OLDRE=$(echo "$OLDNUM" | sed -e 's/\./\\\./g')
NEWRE=$(echo "$NEWNUM" | sed -e 's/\./\\\./g')

................................................................................
$ECHO cd    "../${TAGLABEL}"
$ECHO fossil open "$REPO" "${TAGLABEL}-branch"
$ECHO ./setslabversion -f
$ECHO fossil commit -m "Set version to ${NEWNUM}"
$ECHO fossil tag add "${TAGLABEL}" "$(checkout)"
$ECHO fossil tag add --raw closed  "$(checkout)"
$ECHO fossil push










|
|





>
>
>
>
>
>
>







 







<







 







>
>
>
>
>
>




|







 







<
>
>
>
>







 







<
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
..
27
28
29
30
31
32
33

34
35
36
37
38
39
40
..
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
...
135
136
137
138
139
140
141

142
143
144
145
146
147
148
149
150
151
152
...
198
199
200
201
202
203
204

205
206
207
208
209
210
#!/bin/bash

# ------------------------------------------------------------------------------
# Script for creating a release, with a branch, a tag, and a tarball, from the
# repository of the current checkout.
#
# - The script is useful when a repository holds files with a (fixed) default
#   version number (here, "999"), but tagged releases have a different
#   (and variable) version number.
# ------------------------------------------------------------------------------

# ------------------------------------------------------------------------------
# Project-specific constants.
# ------------------------------------------------------------------------------

VERFILE="SlabVersion.txt"
PROJECT=Slab


# ------------------------------------------------------------------------------
# For testing.
# ------------------------------------------------------------------------------

# Commands that change anything are preceded with $ECHO.
................................................................................
ECHO=


# ------------------------------------------------------------------------------
# Set constants, define functions.
# ------------------------------------------------------------------------------


BASENAME=$(basename $0)

die() {
    if [ $# -ne 0 ]
    then
        echo "$@" >&2
    fi
................................................................................
    exit 1
}

checkout() {
    fossil info|grep '^checkout:'| sed -e 's/^checkout:[[:space:]]*//; s/[[:space:]].*$//'
}

# This does kill the main script, not just a subshell.
die_if_exists() {
    test $# -eq 1   || die "function die_if_exists needs precisely one argument"
    test -e "$1" -o -L "$1" && die "a file \"$1\" already exists."
}


# ------------------------------------------------------------------------------
# CHECK the command arguments, version file, and version,
# user consent, file clobber, pre-existence of any files with the new version,
# pre-existence of directories and tarball.
# ------------------------------------------------------------------------------


# CHECK command arguments:

test "$#" -lt 2 || usage

................................................................................
        die
    fi
else
    echo
fi

NEWDIR="../${TAGLABEL}"


die_if_exists "$NEWDIR"
die_if_exists "../${PROJECT}-${NEWNUM}"
die_if_exists "../${PROJECT}-${NEWNUM}.tar.gz"


# CHECK that the operation will not clobber existing files:

OLDRE=$(echo "$OLDNUM" | sed -e 's/\./\\\./g')
NEWRE=$(echo "$NEWNUM" | sed -e 's/\./\\\./g')

................................................................................
$ECHO cd    "../${TAGLABEL}"
$ECHO fossil open "$REPO" "${TAGLABEL}-branch"
$ECHO ./setslabversion -f
$ECHO fossil commit -m "Set version to ${NEWNUM}"
$ECHO fossil tag add "${TAGLABEL}" "$(checkout)"
$ECHO fossil tag add --raw closed  "$(checkout)"
$ECHO fossil push

$ECHO cd ..
$ECHO cp -a "${TAGLABEL}" "${PROJECT}-${NEWNUM}"
$ECHO cd "${PROJECT}-${NEWNUM}"
$ECHO fossil close
$ECHO cd ..
$ECHO tar -czf "${PROJECT}-${NEWNUM}.tar.gz" "${PROJECT}-${NEWNUM}"