bTagScript 3.1.5__tar.gz → 5.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {bTagScript-3.1.5 → btagscript-5.0.0}/LICENSE +1 -1
- {bTagScript-3.1.5 → btagscript-5.0.0}/PKG-INFO +109 -104
- {bTagScript-3.1.5 → btagscript-5.0.0}/README.md +80 -80
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/__init__.py +66 -66
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/__init__.py +16 -16
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/discord_adapters.py +275 -275
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/function_adapter.py +33 -32
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/int_adapter.py +30 -28
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/object_adapter.py +41 -41
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/adapter/string_adapter.py +69 -69
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/__init__.py +67 -64
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/break_block.py +41 -41
- btagscript-5.0.0/bTagScript/block/case_block.py +62 -0
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/comment_block.py +33 -33
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/control_block.py +161 -162
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/counting_blocks.py +88 -88
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/digitshorthand_block.py +38 -39
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/__init__.py +20 -20
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/command_block.py +52 -52
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/cooldown_block.py +101 -101
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/delete_block.py +47 -47
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/embed_block.py +248 -250
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/override_block.py +61 -61
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/react_block.py +49 -49
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/redirect_block.py +42 -42
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/discord_blocks/requirement_blocks.py +83 -83
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/helpers.py +121 -121
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/math_blocks.py +257 -252
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/random_block.py +65 -63
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/range_block.py +54 -63
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/replace_block.py +110 -110
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/stop_block.py +38 -38
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/strf_block.py +70 -70
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/url_blocks.py +76 -76
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/util_blocks/__init__.py +3 -3
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/util_blocks/debug_block.py +107 -107
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/var_block.py +49 -49
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/block/vargetter_blocks.py +91 -89
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/exceptions.py +139 -139
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/interface/__init__.py +4 -4
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/interface/adapter.py +43 -43
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/interface/block.py +136 -136
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/interpreter.py +614 -633
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/utils.py +65 -65
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript/verb.py +129 -173
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript.egg-info/PKG-INFO +109 -104
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript.egg-info/SOURCES.txt +8 -2
- btagscript-5.0.0/bTagScript.egg-info/requires.txt +2 -0
- btagscript-5.0.0/pyproject.toml +52 -0
- {bTagScript-3.1.5 → btagscript-5.0.0}/setup.cfg +4 -4
- btagscript-5.0.0/tests/test_adapters.py +41 -0
- btagscript-5.0.0/tests/test_async.py +27 -0
- btagscript-5.0.0/tests/test_basic.py +21 -0
- btagscript-5.0.0/tests/test_edgecase.py +156 -0
- btagscript-5.0.0/tests/test_escapes.py +30 -0
- btagscript-5.0.0/tests/test_verbs.py +123 -0
- bTagScript-3.1.5/bTagScript.egg-info/requires.txt +0 -2
- bTagScript-3.1.5/pyproject.toml +0 -10
- bTagScript-3.1.5/setup.py +0 -55
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript.egg-info/dependency_links.txt +0 -0
- {bTagScript-3.1.5 → btagscript-5.0.0}/bTagScript.egg-info/top_level.txt +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
|
|
1
|
+
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
|
|
@@ -1,104 +1,109 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
2
|
-
Name: bTagScript
|
|
3
|
-
Version:
|
|
4
|
-
Summary: An easy drop in user-provided Templating system.
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Classifier:
|
|
15
|
-
Classifier:
|
|
16
|
-
Classifier:
|
|
17
|
-
Classifier:
|
|
18
|
-
Classifier:
|
|
19
|
-
Classifier: Programming Language :: Python :: 3.
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
Download
|
|
66
|
-
|
|
67
|
-
```
|
|
68
|
-
pip(3) install
|
|
69
|
-
```
|
|
70
|
-
|
|
71
|
-
Download
|
|
72
|
-
|
|
73
|
-
```
|
|
74
|
-
pip(3) install
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
```
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: bTagScript
|
|
3
|
+
Version: 5.0.0
|
|
4
|
+
Summary: An easy drop in user-provided Templating system.
|
|
5
|
+
Author-email: Leg3ndary <bleg3ndary@gmail.com>
|
|
6
|
+
Maintainer-email: Leg3ndary <bleg3ndary@gmail.com>
|
|
7
|
+
License: Creative Commons Attribution 4.0 International License
|
|
8
|
+
Project-URL: Homepage, https://github.com/Leg3ndary/bTagScript
|
|
9
|
+
Project-URL: Documentation, https://btagscript.readthedocs.io/
|
|
10
|
+
Keywords: tagscript
|
|
11
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: License :: Freely Distributable
|
|
14
|
+
Classifier: Natural Language :: English
|
|
15
|
+
Classifier: Operating System :: OS Independent
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
22
|
+
Requires-Python: >=3.9
|
|
23
|
+
Description-Content-Type: text/markdown
|
|
24
|
+
License-File: LICENSE
|
|
25
|
+
Requires-Dist: discord.py>=2.0.0
|
|
26
|
+
Requires-Dist: pyparsing>=3.0.9
|
|
27
|
+
Dynamic: license-file
|
|
28
|
+
|
|
29
|
+
# bTagScript
|
|
30
|
+
|
|
31
|
+
<a href='https://btagscript.readthedocs.io/en/latest/?badge=latest'>
|
|
32
|
+
<img src='https://readthedocs.org/projects/btagscript/badge/?version=latest' alt='Documentation Status' />
|
|
33
|
+
</a>
|
|
34
|
+
|
|
35
|
+
TagScript, but better, with more features then you could ever need!
|
|
36
|
+
|
|
37
|
+
**Features:**
|
|
38
|
+
- Extra Syntax Options
|
|
39
|
+
- More Blocks
|
|
40
|
+
|
|
41
|
+
<img width="851" alt="bTagScriptBasic" src="https://i.imgur.com/wHxbwxw.png">
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
Documentation on the bTagScript library can be [found here](https://btagscript.readthedocs.io/en/latest/).
|
|
45
|
+
|
|
46
|
+
## What?
|
|
47
|
+
|
|
48
|
+
TagScript allows you to create low level code, quickly, and easily. This is meant to be used with discord.py 2.0 and is not compatible with other versions.
|
|
49
|
+
|
|
50
|
+
## Credits
|
|
51
|
+
|
|
52
|
+
This repository is a fork of Phenom4n4n's fork of JonSnowbd's [TagScript](https://github.com/JonSnowbd/TagScript), a string templating language.
|
|
53
|
+
|
|
54
|
+
## Dependencies
|
|
55
|
+
|
|
56
|
+
`Python 3.8+`
|
|
57
|
+
|
|
58
|
+
`discord.py 2.0`
|
|
59
|
+
|
|
60
|
+
`pyparsing`
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
## Installation
|
|
64
|
+
|
|
65
|
+
Download through pip
|
|
66
|
+
|
|
67
|
+
```
|
|
68
|
+
pip(3) install bTagScript
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Download the latest version through github:
|
|
72
|
+
|
|
73
|
+
```
|
|
74
|
+
pip(3) install https://github.com/Leg3ndary/bTagScript
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
Download from a commit:
|
|
78
|
+
|
|
79
|
+
```
|
|
80
|
+
pip(3) install git+https://github.com/Leg3ndary/bTagScript.git@<COMMIT_HASH>
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Install for editing/development:
|
|
84
|
+
|
|
85
|
+
```
|
|
86
|
+
git clone https://github.com/Leg3ndary/bTagScript.git
|
|
87
|
+
pip(3) install -e ./bTagScript
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## Benchmarks (Performance Testing)
|
|
91
|
+
|
|
92
|
+
### July 08, 2022
|
|
93
|
+
|
|
94
|
+
Testing for this benchmark used the following seeds and test strings, this was ran `1,000` times.
|
|
95
|
+
|
|
96
|
+
```yaml
|
|
97
|
+
Seeds: {message: Hello, this is my message.}
|
|
98
|
+
Test String: {message} {#:1,2,3,4,5,6,7,8,9,10} {range:1-9} {$variablename:Hello World} {variablename} {message} {strf:Its %A}
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
Note that this was adjusted for different syntax, {=(variablename):Hello World} vs {$variablename:Hello World}
|
|
102
|
+
|
|
103
|
+
bTagScript will likely get worse and worse as more blocks are added...
|
|
104
|
+
|
|
105
|
+
```
|
|
106
|
+
2.6.9 bTagScript: 0.08033132553100586 Seconds
|
|
107
|
+
|
|
108
|
+
2.6.2 TagScript: 0.08630657196044922 Seconds
|
|
109
|
+
```
|
|
@@ -1,81 +1,81 @@
|
|
|
1
|
-
# bTagScript
|
|
2
|
-
|
|
3
|
-
<a href='https://btagscript.readthedocs.io/en/latest/?badge=latest'>
|
|
4
|
-
<img src='https://readthedocs.org/projects/btagscript/badge/?version=latest' alt='Documentation Status' />
|
|
5
|
-
</a>
|
|
6
|
-
|
|
7
|
-
TagScript, but better, with more features then you could ever need!
|
|
8
|
-
|
|
9
|
-
**Features:**
|
|
10
|
-
- Extra Syntax Options
|
|
11
|
-
- More Blocks
|
|
12
|
-
|
|
13
|
-
<img width="851" alt="bTagScriptBasic" src="https://i.imgur.com/wHxbwxw.png">
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
Documentation on the bTagScript library can be [found here](https://btagscript.readthedocs.io/en/latest/).
|
|
17
|
-
|
|
18
|
-
## What?
|
|
19
|
-
|
|
20
|
-
TagScript allows you to create low level code, quickly, and easily. This is meant to be used with discord.py 2.0 and is not compatible with other versions.
|
|
21
|
-
|
|
22
|
-
## Credits
|
|
23
|
-
|
|
24
|
-
This repository is a fork of Phenom4n4n's fork of JonSnowbd's [TagScript](https://github.com/JonSnowbd/TagScript), a string templating language.
|
|
25
|
-
|
|
26
|
-
## Dependencies
|
|
27
|
-
|
|
28
|
-
`Python 3.8+`
|
|
29
|
-
|
|
30
|
-
`discord.py 2.0`
|
|
31
|
-
|
|
32
|
-
`pyparsing`
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
## Installation
|
|
36
|
-
|
|
37
|
-
Download through pip
|
|
38
|
-
|
|
39
|
-
```
|
|
40
|
-
pip(3) install bTagScript
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
Download the latest version through github:
|
|
44
|
-
|
|
45
|
-
```
|
|
46
|
-
pip(3) install https://github.com/Leg3ndary/bTagScript
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
Download from a commit:
|
|
50
|
-
|
|
51
|
-
```
|
|
52
|
-
pip(3) install git+https://github.com/Leg3ndary/bTagScript.git@<COMMIT_HASH>
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
Install for editing/development:
|
|
56
|
-
|
|
57
|
-
```
|
|
58
|
-
git clone https://github.com/Leg3ndary/bTagScript.git
|
|
59
|
-
pip(3) install -e ./bTagScript
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
## Benchmarks (Performance Testing)
|
|
63
|
-
|
|
64
|
-
### July 08, 2022
|
|
65
|
-
|
|
66
|
-
Testing for this benchmark used the following seeds and test strings, this was ran `1,000` times.
|
|
67
|
-
|
|
68
|
-
```yaml
|
|
69
|
-
Seeds: {message: Hello, this is my message.}
|
|
70
|
-
Test String: {message} {#:1,2,3,4,5,6,7,8,9,10} {range:1-9} {$variablename:Hello World} {variablename} {message} {strf:Its %A}
|
|
71
|
-
```
|
|
72
|
-
|
|
73
|
-
Note that this was adjusted for different syntax, {=(variablename):Hello World} vs {$variablename:Hello World}
|
|
74
|
-
|
|
75
|
-
bTagScript will likely get worse and worse as more blocks are added...
|
|
76
|
-
|
|
77
|
-
```
|
|
78
|
-
2.6.9 bTagScript: 0.08033132553100586 Seconds
|
|
79
|
-
|
|
80
|
-
2.6.2 TagScript: 0.08630657196044922 Seconds
|
|
1
|
+
# bTagScript
|
|
2
|
+
|
|
3
|
+
<a href='https://btagscript.readthedocs.io/en/latest/?badge=latest'>
|
|
4
|
+
<img src='https://readthedocs.org/projects/btagscript/badge/?version=latest' alt='Documentation Status' />
|
|
5
|
+
</a>
|
|
6
|
+
|
|
7
|
+
TagScript, but better, with more features then you could ever need!
|
|
8
|
+
|
|
9
|
+
**Features:**
|
|
10
|
+
- Extra Syntax Options
|
|
11
|
+
- More Blocks
|
|
12
|
+
|
|
13
|
+
<img width="851" alt="bTagScriptBasic" src="https://i.imgur.com/wHxbwxw.png">
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
Documentation on the bTagScript library can be [found here](https://btagscript.readthedocs.io/en/latest/).
|
|
17
|
+
|
|
18
|
+
## What?
|
|
19
|
+
|
|
20
|
+
TagScript allows you to create low level code, quickly, and easily. This is meant to be used with discord.py 2.0 and is not compatible with other versions.
|
|
21
|
+
|
|
22
|
+
## Credits
|
|
23
|
+
|
|
24
|
+
This repository is a fork of Phenom4n4n's fork of JonSnowbd's [TagScript](https://github.com/JonSnowbd/TagScript), a string templating language.
|
|
25
|
+
|
|
26
|
+
## Dependencies
|
|
27
|
+
|
|
28
|
+
`Python 3.8+`
|
|
29
|
+
|
|
30
|
+
`discord.py 2.0`
|
|
31
|
+
|
|
32
|
+
`pyparsing`
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
## Installation
|
|
36
|
+
|
|
37
|
+
Download through pip
|
|
38
|
+
|
|
39
|
+
```
|
|
40
|
+
pip(3) install bTagScript
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Download the latest version through github:
|
|
44
|
+
|
|
45
|
+
```
|
|
46
|
+
pip(3) install https://github.com/Leg3ndary/bTagScript
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Download from a commit:
|
|
50
|
+
|
|
51
|
+
```
|
|
52
|
+
pip(3) install git+https://github.com/Leg3ndary/bTagScript.git@<COMMIT_HASH>
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Install for editing/development:
|
|
56
|
+
|
|
57
|
+
```
|
|
58
|
+
git clone https://github.com/Leg3ndary/bTagScript.git
|
|
59
|
+
pip(3) install -e ./bTagScript
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## Benchmarks (Performance Testing)
|
|
63
|
+
|
|
64
|
+
### July 08, 2022
|
|
65
|
+
|
|
66
|
+
Testing for this benchmark used the following seeds and test strings, this was ran `1,000` times.
|
|
67
|
+
|
|
68
|
+
```yaml
|
|
69
|
+
Seeds: {message: Hello, this is my message.}
|
|
70
|
+
Test String: {message} {#:1,2,3,4,5,6,7,8,9,10} {range:1-9} {$variablename:Hello World} {variablename} {message} {strf:Its %A}
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Note that this was adjusted for different syntax, {=(variablename):Hello World} vs {$variablename:Hello World}
|
|
74
|
+
|
|
75
|
+
bTagScript will likely get worse and worse as more blocks are added...
|
|
76
|
+
|
|
77
|
+
```
|
|
78
|
+
2.6.9 bTagScript: 0.08033132553100586 Seconds
|
|
79
|
+
|
|
80
|
+
2.6.2 TagScript: 0.08630657196044922 Seconds
|
|
81
81
|
```
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
"""
|
|
2
|
-
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license,
|
|
3
|
-
visit http://creativecommons.org/licenses/by/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
|
|
4
|
-
|
|
5
|
-
This fork was made by _Leg3ndary and contains everything he thought should be added to tagscript. Hope you enjoy!
|
|
6
|
-
"""
|
|
7
|
-
|
|
8
|
-
from collections import namedtuple
|
|
9
|
-
|
|
10
|
-
from .adapter import *
|
|
11
|
-
from .block import *
|
|
12
|
-
from .exceptions import *
|
|
13
|
-
from .interface import *
|
|
14
|
-
from .interpreter import *
|
|
15
|
-
from .utils import *
|
|
16
|
-
from .verb import Verb
|
|
17
|
-
|
|
18
|
-
__version__ = "
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
class VersionInfo(namedtuple("VersionInfo", "major minor micro")):
|
|
22
|
-
"""
|
|
23
|
-
Version information.
|
|
24
|
-
|
|
25
|
-
Attributes
|
|
26
|
-
----------
|
|
27
|
-
major: int
|
|
28
|
-
Major version number.
|
|
29
|
-
minor: int
|
|
30
|
-
Minor version number.
|
|
31
|
-
micro: int
|
|
32
|
-
Micro version number.
|
|
33
|
-
"""
|
|
34
|
-
|
|
35
|
-
__slots__ = ()
|
|
36
|
-
|
|
37
|
-
def __str__(self):
|
|
38
|
-
"""
|
|
39
|
-
Returns a string representation of the version information.
|
|
40
|
-
|
|
41
|
-
Returns
|
|
42
|
-
-------
|
|
43
|
-
str
|
|
44
|
-
String representation of the version information.
|
|
45
|
-
"""
|
|
46
|
-
return "{major}.{minor}.{micro}".format(**self._asdict())
|
|
47
|
-
|
|
48
|
-
@classmethod
|
|
49
|
-
def from_str(cls, version):
|
|
50
|
-
"""
|
|
51
|
-
Returns a VersionInfo instance from a string.
|
|
52
|
-
|
|
53
|
-
Parameters
|
|
54
|
-
----------
|
|
55
|
-
version: str
|
|
56
|
-
String representation of the version information.
|
|
57
|
-
|
|
58
|
-
Returns
|
|
59
|
-
-------
|
|
60
|
-
VersionInfo
|
|
61
|
-
Version information.
|
|
62
|
-
"""
|
|
63
|
-
return cls(*map(int, version.split(".")))
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
version_info = VersionInfo.from_str(__version__)
|
|
1
|
+
"""
|
|
2
|
+
This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license,
|
|
3
|
+
visit http://creativecommons.org/licenses/by/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
|
|
4
|
+
|
|
5
|
+
This fork was made by _Leg3ndary and contains everything he thought should be added to tagscript. Hope you enjoy!
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
from collections import namedtuple
|
|
9
|
+
|
|
10
|
+
from .adapter import *
|
|
11
|
+
from .block import *
|
|
12
|
+
from .exceptions import *
|
|
13
|
+
from .interface import *
|
|
14
|
+
from .interpreter import *
|
|
15
|
+
from .utils import *
|
|
16
|
+
from .verb import Verb
|
|
17
|
+
|
|
18
|
+
__version__ = "5.0.0"
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class VersionInfo(namedtuple("VersionInfo", "major minor micro")):
|
|
22
|
+
"""
|
|
23
|
+
Version information.
|
|
24
|
+
|
|
25
|
+
Attributes
|
|
26
|
+
----------
|
|
27
|
+
major: int
|
|
28
|
+
Major version number.
|
|
29
|
+
minor: int
|
|
30
|
+
Minor version number.
|
|
31
|
+
micro: int
|
|
32
|
+
Micro version number.
|
|
33
|
+
"""
|
|
34
|
+
|
|
35
|
+
__slots__ = ()
|
|
36
|
+
|
|
37
|
+
def __str__(self):
|
|
38
|
+
"""
|
|
39
|
+
Returns a string representation of the version information.
|
|
40
|
+
|
|
41
|
+
Returns
|
|
42
|
+
-------
|
|
43
|
+
str
|
|
44
|
+
String representation of the version information.
|
|
45
|
+
"""
|
|
46
|
+
return "{major}.{minor}.{micro}".format(**self._asdict())
|
|
47
|
+
|
|
48
|
+
@classmethod
|
|
49
|
+
def from_str(cls, version):
|
|
50
|
+
"""
|
|
51
|
+
Returns a VersionInfo instance from a string.
|
|
52
|
+
|
|
53
|
+
Parameters
|
|
54
|
+
----------
|
|
55
|
+
version: str
|
|
56
|
+
String representation of the version information.
|
|
57
|
+
|
|
58
|
+
Returns
|
|
59
|
+
-------
|
|
60
|
+
VersionInfo
|
|
61
|
+
Version information.
|
|
62
|
+
"""
|
|
63
|
+
return cls(*map(int, version.split(".")))
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
version_info = VersionInfo.from_str(__version__)
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
from .discord_adapters import *
|
|
2
|
-
from .function_adapter import FunctionAdapter
|
|
3
|
-
from .int_adapter import IntAdapter
|
|
4
|
-
from .object_adapter import SafeObjectAdapter
|
|
5
|
-
from .string_adapter import StringAdapter
|
|
6
|
-
|
|
7
|
-
__all__ = (
|
|
8
|
-
"SafeObjectAdapter",
|
|
9
|
-
"StringAdapter",
|
|
10
|
-
"IntAdapter",
|
|
11
|
-
"FunctionAdapter",
|
|
12
|
-
"AttributeAdapter",
|
|
13
|
-
"MemberAdapter",
|
|
14
|
-
"ChannelAdapter",
|
|
15
|
-
"GuildAdapter",
|
|
16
|
-
)
|
|
1
|
+
from .discord_adapters import *
|
|
2
|
+
from .function_adapter import FunctionAdapter
|
|
3
|
+
from .int_adapter import IntAdapter
|
|
4
|
+
from .object_adapter import SafeObjectAdapter
|
|
5
|
+
from .string_adapter import StringAdapter
|
|
6
|
+
|
|
7
|
+
__all__ = (
|
|
8
|
+
"SafeObjectAdapter",
|
|
9
|
+
"StringAdapter",
|
|
10
|
+
"IntAdapter",
|
|
11
|
+
"FunctionAdapter",
|
|
12
|
+
"AttributeAdapter",
|
|
13
|
+
"MemberAdapter",
|
|
14
|
+
"ChannelAdapter",
|
|
15
|
+
"GuildAdapter",
|
|
16
|
+
)
|