Comments (3)
Excluding a single .hidden
item is different from excluding all items with the name .hidden
.
The -e
/ --exclude
option does not do pattern matching. It is just for excluding specific files/folders. To make your example work you could change the cmdline to py3createtorrent.exe -v -e d:\hidden-folder-test\.hidden d:\hidden-folder-test
i.e. provide full path to the .hidden
folder so that it can be recognized by py3createtorrent (unambiguously).
If you want to exclude all files/folders that have the name ".hidden" then you can try the --exclude-pattern
option.
from py3createtorrent.
I just tested this with a folder starting with ".". For me it works:
C:\Users\Robert\Desktop\hidden-folder-test
λ ls -Al
total 1
drwxr-xr-x 1 Robert 197121 0 Mrz 13 09:39 .hidden/
-rw-r--r-- 1 Robert 197121 10 Mrz 13 09:39 file_outside_of_hidden_folder.txt
C:\Users\Robert\Desktop\hidden-folder-test
λ py3createtorrent.exe -v --exclude .hidden .
Path to config file: C:\Users\Robert\.py3createtorrent.cfg
Config file does not exist
Config / Tracker abbreviations:
{'coppersurfer': 'udp://tracker.coppersurfer.tk:6969/announce',
'cyberia': 'udp://tracker.cyberia.is:6969/announce',
'opentrackr': 'udp://tracker.opentrackr.org:1337/announce'}
Config / Advertise: True
Config / Best trackers URL: https://raw.githubusercontent.com/ngosang/trackerslist/master/trackers_best.txt
Skipping '.hidden' due to explicit exclusion.
Processing file 'file_outside_of_hidden_folder.txt'... done
Successfully created torrent:
Name: hidden-folder-test
Size: 0 KiB
Pieces: 1 x 16 KiB
Comment: created with py3createtorrent v1.0.1
Private: no
Creation date: 2022-03-13 09:41:19
DHT bootstrap nodes: (none)
Webseeds: (none)
Primary tracker: (none)
Backup trackers:
(none)
Can you please show a more complete example including the full command that you are using as well as the layout of the files in the folder?
from py3createtorrent.
It seems to be related to the absolute path i'm using. it cant find the .folder that why it is not excluded.
here is my cmdline
H:\>py3createtorrent.exe -v -e .hidden d:\hidden-folder-test
Path to config file: C:\Users\Patrick\.py3createtorrent.cfg
Config file does not exist
Config / Tracker abbreviations:
{'coppersurfer': 'udp://tracker.coppersurfer.tk:6969/announce',
'cyberia': 'udp://tracker.cyberia.is:6969/announce',
'opentrackr': 'udp://tracker.opentrackr.org:1337/announce'}
Config / Advertise: True
Config / Best trackers URL: https://raw.githubusercontent.com/ngosang/trackerslist/master/trackers_best.txt
Warning: You're excluding a path that does not exist: 'h:\.hidden'
Processing file '.hidden\.hidden.txt.bak'... done
Processing file '.hidden\.hidden_file_inside.txt'... done
Processing file 'hidden-folder-test.torrent'... done
Processing file 'hidden.txt.bak'... done
Processing file 'hidden_file_outside.txt'... done
Successfully created torrent:
Name: hidden-folder-test
Size: 0 KiB
Pieces: 1 x 16 KiB
Comment: created with py3createtorrent v1.0.1
Private: no
Creation date: 2022-03-13 10:33:19
DHT bootstrap nodes: (none)
Webseeds: (none)
Primary tracker: (none)
Backup trackers:
(none)
When I omit the drive portion so I make it a relative path. It is working like your example.
from py3createtorrent.
Related Issues (17)
- About RegEx issue HOT 3
- Faulty torrent name and 'name' field when using relative path '.'
- Support for usage as a module HOT 9
- Support for optimise alignment (Piece-Aligned, BEP-47) ?
- Make "master" the default branch again HOT 3
- No way to populate a "source" field? HOT 2
- Trackerless torrent HOT 3
- UnicodeEncodeError HOT 6
- Is 16MiB a hard limit for max pieces size? HOT 2
- Remove created_by attribute HOT 1
- run fails with "SyntaxError: invalid syntax" HOT 3
- noob question
- Where is the config file? HOT 4
- Support for v2 and hybrid torrent files HOT 2
- Torrent name assignment HOT 8
- Error with path exceeded than 260 characters in Windows HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from py3createtorrent.