Commit 505e1ad
committed
feat: Implement and integrate --export functionality
This commit introduces the new `--export` (-e) feature to PyAte.
The export functionality allows users to specify a file containing OTP URIs
which will then be processed to generate QR codes for each valid URI.
Key changes include:
Added logic to handle the `--export` argument, specifying the input file for QR code generation.
Implemented file reading and URI parsing to extract valid `otpauth://` URIs.
Integrated QR code generation using `generateQrcodeFromUri` to create PNG files in a 'qrcodes' directory.
Improved error handling for file operations and URI parsing during export.
Corrected the logic to properly use the `--export` argument's value (or its default) for reading the account file, resolving a previous issue where `args.read` was incorrectly used.1 parent e0fb1e3 commit 505e1ad
1 file changed
Lines changed: 48 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| |||
119 | 119 | | |
120 | 120 | | |
121 | 121 | | |
| 122 | + | |
| 123 | + | |
122 | 124 | | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
123 | 169 | | |
124 | 170 | | |
125 | 171 | | |
| |||
207 | 253 | | |
208 | 254 | | |
209 | 255 | | |
210 | | - | |
| 256 | + | |
211 | 257 | | |
212 | 258 | | |
213 | 259 | | |
| |||
0 commit comments