Skip to content

Commit 2680920

Browse files
authored
Merge pull request #6 from fragmuffin/develop
0.2.0
2 parents 75022b6 + bb0ab66 commit 2680920

57 files changed

Lines changed: 8375 additions & 133 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

deployment/README.md

Lines changed: 119 additions & 111 deletions
Original file line numberDiff line numberDiff line change
@@ -9,54 +9,53 @@ this can help.
99

1010
Method based on the articles:
1111

12-
* http://peterdowns.com/posts/first-time-with-pypi.html and
13-
* https://hynek.me/articles/sharing-your-labor-of-love-pypi-quick-and-dirty/
12+
* http://peterdowns.com/posts/first-time-with-pypi.html and
13+
* https://hynek.me/articles/sharing-your-labor-of-love-pypi-quick-and-dirty/
1414

1515

1616
Deployment also heavily uses the `./deploy.sh` script in this folder.
1717
At this time, running `./deploy.sh --help` displays:
1818

19-
```
20-
Usage: ./deploy.sh {build|test|and so on ...}
19+
Usage: ./deploy.sh {build|test|and so on ...}
2120

22-
This script is to maintain a consistent method of deployment and testing.
21+
This script is to maintain a consistent method of deployment and testing.
2322

24-
Deployment target: pygcode 0.1.1.dev0
23+
Deployment target: pygcode 0.2.0
2524

26-
Arguments:
27-
Setup:
28-
setup: Installs packages & sets up environment (requires sudo)
25+
Arguments:
26+
Setup:
27+
setup: Installs packages & sets up environment (requires sudo)
2928

30-
Compiling:
31-
build: Execute setup to build packages (populates ../dist/)
32-
creates both 'sdist' and 'wheel' distrobutions.
29+
Compiling:
30+
build: Execute setup to build packages (populates ../dist/)
31+
creates both 'sdist' and 'wheel' distrobutions.
3332

34-
Virtual Environments:
35-
rmenv py# Remove virtual environment
36-
remkenv py# Remove, then create re-create virtual environment
37-
envprereq py# install environment prerequisites (official PyPi)
33+
Virtual Environments:
34+
lsenv List created virtual environments for this lib
35+
rmenv py# Remove virtual environment
36+
remkenv py# Remove, then create re-create virtual environment
37+
envprereq py# install environment prerequisites (official PyPi)
3838

39-
Deploy:
40-
deploy test Upload to PyPi test server
41-
deploy prod Upload to PyPi (official)
39+
Deploy:
40+
deploy test Upload to PyPi test server
41+
deploy prod Upload to PyPi (official)
4242

43-
Install:
44-
install sdist py# Install from local sdist
45-
install wheel py# Install from local wheel
46-
install pypitest py# Install from PyPi test server
47-
install pypi py# Install from PyPi (official)
43+
Install:
44+
install sdist py# Install from local sdist
45+
install wheel py# Install from local wheel
46+
install pypitest py# Install from PyPi test server
47+
install pypi py# Install from PyPi (official)
4848

49-
Testing:
50-
test dev py# Run tests on local dev in a virtual env
51-
test installed py# Run tests on installed library in virtual env
49+
Testing:
50+
test dev py# Run tests on local dev in a virtual env
51+
test installed py# Run tests on installed library in virtual env
5252

53-
Help:
54-
-h | --help display this help message
53+
Help:
54+
-h | --help display this help message
5555

56-
py#: when referenced above means
57-
'py2' for Python 2.7.12
58-
'py3' for Python 3.5.2
59-
```
56+
py#: when referenced above means
57+
'py2' for Python 2.7.12
58+
'py3' for Python 3.5.2
6059

6160
# PyPi deployment
6261

@@ -68,82 +67,77 @@ Arguments:
6867

6968
`cat ~/.pypirc`
7069

71-
```
72-
[distutils]
73-
index-servers =
74-
prod
75-
test
70+
[distutils]
71+
index-servers =
72+
prod
73+
test
7674

77-
[prod]
78-
repository = https://upload.pypi.org/legacy/
79-
username=FraggaMuffin
80-
password=secret
75+
[prod]
76+
repository = https://upload.pypi.org/legacy/
77+
username=FraggaMuffin
78+
password=secret
8179

82-
[test]
83-
repository=https://test.pypi.org/legacy/
84-
username=FraggaMuffin
85-
password=secret
86-
```
80+
[test]
81+
repository=https://test.pypi.org/legacy/
82+
username=FraggaMuffin
83+
password=secret
8784

8885
`chmod 600 ~/.pypirc`
8986

9087

9188
## Build and Test `sdist` and `wheel`
9289

9390
**Build**
94-
```
95-
./deploy.sh build
96-
```
91+
92+
./deploy.sh build
9793

9894
**Test `sdist`**
99-
```
100-
# Python 2.x
101-
./deploy.sh remkenv py2
102-
./deploy.sh envprereq py2
103-
./deploy.sh install sdist py2
104-
./deploy.sh test installed py2
105-
106-
# Python 3.x
107-
./deploy.sh remkenv py3
108-
./deploy.sh envprereq py3
109-
./deploy.sh install sdist py3
110-
./deploy.sh test installed py3
111-
```
95+
96+
# Python 2.x
97+
./deploy.sh remkenv py2
98+
./deploy.sh envprereq py2
99+
./deploy.sh install sdist py2
100+
./deploy.sh test installed py2
101+
102+
# Python 3.x
103+
./deploy.sh remkenv py3
104+
./deploy.sh envprereq py3
105+
./deploy.sh install sdist py3
106+
./deploy.sh test installed py3
112107

113108
**Test `wheel`**
114-
```
115-
# Python 2.x
116-
./deploy.sh remkenv py2
117-
./deploy.sh install wheel py2
118-
./deploy.sh test installed py2
119109

120-
# Python 3.x
121-
./deploy.sh remkenv py3
122-
./deploy.sh install wheel py3
123-
./deploy.sh test installed py3
124-
```
110+
# Python 2.x
111+
./deploy.sh remkenv py2
112+
./deploy.sh install wheel py2
113+
./deploy.sh test installed py2
114+
115+
# Python 3.x
116+
./deploy.sh remkenv py3
117+
./deploy.sh install wheel py3
118+
./deploy.sh test installed py3
119+
125120

126121

127122
## Upload to PyPi Test server
128123

129-
```
130-
./deploy.sh deploy test
131-
```
124+
125+
./deploy.sh deploy test
126+
132127

133128
**Test**
134-
```
135-
# Python 2.x
136-
./deploy.sh remkenv py2
137-
./deploy.sh envprereq py2
138-
./deploy.sh install pypitest py2
139-
./deploy.sh test installed py2
140-
141-
# Python 3.x
142-
./deploy.sh remkenv py3
143-
./deploy.sh envprereq py3
144-
./deploy.sh install pypitest py3
145-
./deploy.sh test installed py3
146-
```
129+
130+
# Python 2.x
131+
./deploy.sh remkenv py2
132+
./deploy.sh envprereq py2
133+
./deploy.sh install pypitest py2
134+
./deploy.sh test installed py2
135+
136+
# Python 3.x
137+
./deploy.sh remkenv py3
138+
./deploy.sh envprereq py3
139+
./deploy.sh install pypitest py3
140+
./deploy.sh test installed py3
147141

148142
have a look at:
149143
https://testpypi.python.org/pypi/pygcode
@@ -154,22 +148,19 @@ to make sure it's sane
154148

155149
all good!? sweet :+1: time to upload to 'production'
156150

157-
```
158-
./deploy.sh deploy prod
159-
```
151+
./deploy.sh deploy prod
160152

161153
**Test**
162-
```
163-
# Python 2.x
164-
./deploy.sh remkenv py2
165-
./deploy.sh install pypi py2
166-
./deploy.sh test installed py2
167-
168-
# Python 3.x
169-
./deploy.sh remkenv py3
170-
./deploy.sh install pypi py3
171-
./deploy.sh test installed py3
172-
```
154+
155+
# Python 2.x
156+
./deploy.sh remkenv py2
157+
./deploy.sh install pypi py2
158+
./deploy.sh test installed py2
159+
160+
# Python 3.x
161+
./deploy.sh remkenv py3
162+
./deploy.sh install pypi py3
163+
./deploy.sh test installed py3
173164

174165
have a look at:
175166
https://pypi.python.org/pypi/pygcode
@@ -178,15 +169,32 @@ to make sure it's sane
178169

179170
# Deployment in Git
180171

181-
merge deployed branch to `master`, then...
172+
create pull request `develop` -> `master`
173+
174+
## Update change log
175+
176+
update [change log](../dist/README.md)
177+
178+
## Push Release to Git (aka `tag`)
179+
180+
merge `develop` branch to `master`, then...
182181

183-
```
184-
git checkout master
185-
git pull
186-
git tag ${version} -m "<change description>"
187-
git push --tags origin master
188-
```
182+
Switch local to `master` and tag with relevant version
189183

190-
have a look at the [releases page](https://github.com/fragmuffin/pygcode/releases) and it should be there.
184+
git checkout master
185+
git pull
186+
git tag ${version} -m "<change description>"
187+
git push --tags origin master
188+
189+
have a look at the
190+
[releases page](https://github.com/fragmuffin/pygcode/releases)
191+
and it should be there.
192+
193+
edit release and copy relevant content from [change log](../dist/README.md)
191194

192195
tadaaaaaa!... go to sleep; it's probably late
196+
197+
# Cleanup
198+
199+
./deploy.sh rmenv py2
200+
./deploy.sh rmenv py3

deployment/deploy.sh

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ Arguments:
4242
creates both 'sdist' and 'wheel' distrobutions.
4343
4444
Virtual Environments:
45+
lsenv List created virtual environments for this lib
4546
rmenv py# Remove virtual environment
4647
remkenv py# Remove, then create re-create virtual environment
4748
envprereq py# install environment prerequisites (official PyPi)
@@ -83,6 +84,10 @@ function build() {
8384
popd
8485
}
8586

87+
function lsenv() {
88+
lsvirtualenv -b | grep ^${LIB_NAME}_
89+
}
90+
8691
function rmenv() {
8792
# Remove virtual environment
8893
set_venv_variables $1
@@ -210,6 +215,7 @@ case "$1" in
210215
# Valid Commands
211216
setup) setup ;;
212217
build) build ;;
218+
lsenv) lsenv ;;
213219
rmenv) rmenv $2 ;;
214220
remkenv) remkenv $2 ;;
215221
envprereq) envprereq $2 ;;
@@ -224,4 +230,4 @@ case "$1" in
224230
;;
225231
esac
226232

227-
echo ./${0##*/} completed successfully
233+
#echo ./${0##*/} completed successfully

dist/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,25 @@
11
# Change History
22

3+
## 0.2.0
4+
5+
Moved to `alpha`
6+
7+
Improvements to read more versatile formats
8+
9+
### Improvements
10+
11+
* Tests include a sample-set of gcode files from varying CAM software and authors.
12+
* `lsenv` in deployment script.
13+
* added `GCodeLineNumber` and `GCodeProgramName` (in response to [#5](https://github.com/fragmuffin/pygcode/issues/5)).
14+
* `GCodeCancelCannedCycle` sets machine mode to `None`, and is run first in list of `motion` gcodes.
15+
* Error message for unsupported gcodes is more helpful / relevant.
16+
* Optional whitespace in `Word`, (eg: `X-1.2` and `X -1.2` are now both valid)
17+
18+
### Bugfixes
19+
20+
* [#5](https://github.com/fragmuffin/pygcode/issues/5) Line number in program
21+
22+
323
## 0.1.2
424

525
Changes to accommodate implementation of [grbl-stream](https://github.com/fragmuffin/grbl-stream)
-56.4 KB
Binary file not shown.

dist/pygcode-0.1.2.tar.gz

-39.4 KB
Binary file not shown.
56.9 KB
Binary file not shown.

dist/pygcode-0.2.0.tar.gz

39.9 KB
Binary file not shown.

src/pygcode.egg-info/PKG-INFO

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Metadata-Version: 1.1
22
Name: pygcode
3-
Version: 0.1.2
3+
Version: 0.2.0
44
Summary: Basic g-code parser, interpreter, and encoder library.
55
Home-page: https://github.com/fragmuffin/pygcode
66
Author: Peter Boin

src/pygcode/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# 1.x - Development Status :: 5 - Production/Stable
77
# <any above>.y - developments on that version (pre-release)
88
# <any above>*.dev* - development release (intended purely to test deployment)
9-
__version__ = "0.1.2"
9+
__version__ = "0.2.0"
1010

1111
__title__ = "pygcode"
1212
__description__ = "Basic g-code parser, interpreter, and encoder library."

0 commit comments

Comments
 (0)