{"id":16967462,"url":"https://github.com/tgentil/sortnfc-es","last_synced_at":"2025-03-21T18:16:33.517Z","repository":{"id":155365672,"uuid":"607866625","full_name":"Tgentil/sortNFC-Es","owner":"Tgentil","description":"This script organizes XML files from NF-e (Brazilian Electronic Invoice) based on their payment type. The XML files are moved to different directories according to the payment type: \\example\\folder\\money for cash payments and \\example\\folder\\outher for card payments.","archived":false,"fork":false,"pushed_at":"2023-03-01T16:55:51.000Z","size":3,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-20T08:43:31.548Z","etag":null,"topics":["english","nfce","nfe","python","sorting","xml"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Tgentil.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-02-28T20:49:09.000Z","updated_at":"2024-01-11T17:21:39.000Z","dependencies_parsed_at":null,"dependency_job_id":"ab450e76-7894-4a7d-b468-a1f4f7bbbbaf","html_url":"https://github.com/Tgentil/sortNFC-Es","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tgentil%2FsortNFC-Es","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tgentil%2FsortNFC-Es/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tgentil%2FsortNFC-Es/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Tgentil%2FsortNFC-Es/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Tgentil","download_url":"https://codeload.github.com/Tgentil/sortNFC-Es/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244844532,"owners_count":20519790,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["english","nfce","nfe","python","sorting","xml"],"created_at":"2024-10-14T00:08:41.306Z","updated_at":"2025-03-21T18:16:33.486Z","avatar_url":"https://github.com/Tgentil.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# XML Organizer\n\nThis script organizes XML files from NF-e (Brazilian Electronic Invoice) based on their payment type. The XML files are moved to different directories according to the payment type: `\\example\\folder\\money` for cash payments and `\\example\\folder\\outher` for card payments.\n\n## Implementation\n\nThe script is implemented in Python and uses the following libraries:\n\n- `shutil` for file manipulation\n- `os` for directory listing\n- `xml.etree.ElementTree` for parsing the XML files\n\nThe script works by reading each XML file in the specified directory, parsing it to obtain the payment type, and moving it to the appropriate directory. The directory paths can be configured by changing the `DIRECTORY` and `DESTINATION` constants in the script.\n\n## Setup\n\n1. Clone this repository or download the ZIP file.\n2. Make sure you have Python 3 installed.\n3. Install the required libraries by running `pip install -r requirements.txt` in the project directory.\n4. Configure the `DIRECTORY` and `DESTINATION` constants in the script according to your needs.\n5. Run the script with `python organize_xml.py`.\n\nThat's it! The XML files in the specified directory should now be organized according to their payment type.\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftgentil%2Fsortnfc-es","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftgentil%2Fsortnfc-es","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftgentil%2Fsortnfc-es/lists"}