File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -5,8 +5,7 @@ This is a little similar implementation of `genpy` for uPy. In order to use ross
5
5
## Features
6
6
7
7
- [x] uPy files gen with publish availability
8
- - [ ] uPy files gen with subscribe availability
9
- - [ ] Actions
8
+ - [x] uPy files gen with subscribe availability
10
9
- [ ] Services
11
10
12
11
## Installation
Original file line number Diff line number Diff line change @@ -50,6 +50,11 @@ def create_message(self):
50
50
script_addr = self .addr .split ('/' )[0 ]
51
51
script_name = self .addr .split ('/' )[1 ].split ('.' )[0 ]
52
52
53
+ #manage init file
54
+ initpy = open ("{}/__init__.py" .format (script_addr ), 'a' )
55
+ initpy .write ('from ._{} import {}\n ' .format (script_name , script_name ))
56
+ initpy .close ()
57
+
53
58
#script created
54
59
script = open ("{}/_{}.py" .format (script_addr ,script_name ), 'w' )
55
60
#import input
You can’t perform that action at this time.
0 commit comments