File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change
1
+ strip-hints==0.1.9
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ # ./patch-python3.6.sh
3
+ set -o errexit -o nounset -o pipefail -o xtrace
4
+
5
+ command -v strip-hints
6
+
7
+ for f in $( find datastream/ -name ' *.py' ) ;
8
+ do
9
+ sed -i ' s/#.*//g' $f ;
10
+ strip-hints $f --to-empty --strip-nl > /tmp/.stripped_hints;
11
+ mv /tmp/.stripped_hints $f ;
12
+ sed -i ' /from __future__ import annotations/d' $f ;
13
+ sed -i ' s/Generic\(\[[A-Z]\]\)\?\(\s*,\s*\)\?//g' $f ;
14
+ sed -i ' s/#//g' $f ;
15
+ done
16
+
17
+ sed -i ' s/Dataset\[[A-Z]\]/Dataset/g' datastream/datastream.py;
18
+
19
+ sed -i -E ' s/(Programming *Language *:: *Python *:: *)3.7/\13.6/' setup.cfg
20
+ sed -i ' /Programming Language :: Python :: 3.8/d' setup.cfg
21
+
22
+ sed -i ' s/python/python3.6/g' publish.sh
23
+ sed -i -E ' s/(VERSION_TAG=)(.*)(")$/\1\2+python3.6\3/' publish.sh
24
+ sed -i ' /test -z.*exit 2/d' publish.sh
25
+ sed -i ' /test -z.*exit 3/d' publish.sh
You can’t perform that action at this time.
0 commit comments