{"id":24828215,"url":"https://github.com/orestes7054/acme","last_synced_at":"2026-05-04T06:33:25.417Z","repository":{"id":57679912,"uuid":"492890006","full_name":"orestes7054/acme","owner":"orestes7054","description":"App to calculate salary of Acme's Employees","archived":false,"fork":false,"pushed_at":"2023-05-08T16:17:34.000Z","size":111,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-30T22:51:44.759Z","etag":null,"topics":["pip","python","python3"],"latest_commit_sha":null,"homepage":"","language":"Jupyter Notebook","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/orestes7054.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-05-16T15:16:58.000Z","updated_at":"2022-11-16T00:21:24.000Z","dependencies_parsed_at":"2022-09-01T08:41:20.800Z","dependency_job_id":null,"html_url":"https://github.com/orestes7054/acme","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/orestes7054%2Facme","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orestes7054%2Facme/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orestes7054%2Facme/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/orestes7054%2Facme/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/orestes7054","download_url":"https://codeload.github.com/orestes7054/acme/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245568924,"owners_count":20636864,"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":["pip","python","python3"],"created_at":"2025-01-30T22:51:48.708Z","updated_at":"2026-05-04T06:33:25.387Z","avatar_url":"https://github.com/orestes7054.png","language":"Jupyter Notebook","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n### Architecture\nThe main function of the program is to compute the total payment amount for the employees of the ACME Company. The input is a .txt file with this format:\n\u003cpre\u003eRENE=MO10:00-12:00,TU10:00-12:00,TH01:00-03:00,SA14:00-18:00,SU20:00-21:00\u003c/pre\u003e\n**The output:**\n\u003cpre\u003eThe amount to pay RENE is: 215 USD\u003c/pre\u003e\n\u003cbody\u003e\n\t\u003ch1\u003eDirectory Tree\u003c/h1\u003e\u003cp\u003e\n\t\u003ca href=\"./\"\u003e./\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//ACME/\"\u003eACME\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/acme.txt\"\u003eacme.txt\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/errors.py\"\u003eerrors.py\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/__init__.py\"\u003e__init__.py\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/__main__.py\"\u003e__main__.py\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/payment_class.py\"\u003epayment_class.py\u003c/a\u003e\u003cbr\u003e\n\t│   ├── \u003ca href=\".//ACME/payment.json\"\u003epayment.json\u003c/a\u003e\u003cbr\u003e\n\t│   └── \u003ca href=\".//ACME/utils.py\"\u003eutils.py\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//acme_employee_payment_roll.txt\"\u003eacme_employee_payment_roll.txt\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//LICENSE\"\u003eLICENSE\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//README.md\"\u003eREADME.md\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//result.html\"\u003eresult.html\u003c/a\u003e\u003cbr\u003e\n\t├── \u003ca href=\".//setup.py\"\u003esetup.py\u003c/a\u003e\u003cbr\u003e\n\t└── \u003ca href=\".//test/\"\u003etest\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; ├── \u003ca href=\".//test/data/\"\u003edata\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; │   ├── \u003ca href=\".//test/data/empty_file.txt\"\u003eempty_file.txt\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; │   ├── \u003ca href=\".//test/data/test_acme_five_employees.txt\"\u003etest_acme_five_employees.txt\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; │   ├── \u003ca href=\".//test/data/test_acme.txt\"\u003etest_acme.txt\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; │   └── \u003ca href=\".//test/data/wrong_format.jpg\"\u003ewrong_format.jpg\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; ├── \u003ca href=\".//test/__init__.py\"\u003e__init__.py\u003c/a\u003e\u003cbr\u003e\n\t\u0026nbsp;\u0026nbsp;\u0026nbsp; └── \u003ca href=\".//test/test_acme.py\"\u003etest_acme.py\u003c/a\u003e\u003cbr\u003e\n\t\u003cbr\u003e\u003cbr\u003e\n\t\u003c/p\u003e\n\t\u003cp\u003e\n\n5 directories, 25 files\n\t\u003cbr\u003e\u003cbr\u003e\n\t\u003c/p\u003e\n\t\u003chr\u003e\n\u003c/body\u003e\n\nSorted by hierarchy the ACME file contains the core operations. In **payment_class.py** is the main class that make the computation. In **utils.py** are the function to check the user's input, clear the data and transform text to datetime objects. In **errors.py** are the classes for erorrs. *I tried to keep the project as simple as posible and don't abuse the Classes' use; avoiding the re-calling of simple functions*. The **test** folder includes all the neccesary elements to test the code. The **setup.py** is use to create all the neccesaries elements to make a module of every folder with no problems. [Related to setup.py](https://xkcd.com/353/) \n\u003cp\u003eIn the \u003cb\u003eutils.py\u003c/b\u003e the functions are concatenate, this is a practice I inherit from \u003ca href=\"https://docs.microsoft.com/en-us/office/vba/library-reference/concepts/getting-started-with-vba-in-office\"\u003eVBA\u003c/a\u003e where you usually call a function from a function and run the program consecutively, this is also use in \u003ca href=\"https://www.google.com/script/start/\"\u003eGoogle Apps Script\u003c/a\u003e. The days and payment information is in the payment.json file; the AcmeEmployee class reads this file and obtain the data.\n\t\n![ACME](https://user-images.githubusercontent.com/56367486/168681520-803e911a-0576-4711-a833-125dba40cea0.PNG)\n\t\n\t\n### Installation via PIP\n\tpip install acme-ioet-orestes\n\u003cp\u003eThen use terminal with:\u003c/p\u003e\n\u003cp\u003eFor instructions\u003c/p\u003e\n\u003cpre\u003eACME -h\u003c/pre\u003e\n\u003cp\u003eTo see and example:\u003c/p\u003e\n\u003cpre\u003eACME -example\u003c/pre\u003e\n\u003cp\u003eTo use the program\u003c/p\u003e\n\u003cpre\u003eACME \u0026#60path to the .txt file\u0026#62\u003c/pre\u003e\n\u003cp\u003eIf you want to save a copy of the output:\u003c/p\u003e\n\u003cpre\u003eACME -sc \u0026#60path to the .txt file\u0026#62\u003c/pre\u003e\n\n### Manual Installation\n\u003cpre\u003egit clone https://github.com/orestes7054/acme.git\u003c/pre\u003e\n\u003cpre\u003ecd acme\u003c/pre\u003e\n\u003cpre\u003epip install .\u003c/pre\u003e\n\u003cp\u003eFor instructions\u003c/p\u003e\n\u003cpre\u003epython ACME -h\u003c/pre\u003e\n\u003cp\u003eTo see and example:\u003c/p\u003e\n\u003cpre\u003epython ACME -example\u003c/pre\u003e\n\u003cp\u003eTo use the program\u003c/p\u003e\n\u003cpre\u003epython ACME \u0026#60path to the .txt file\u0026#62\u003c/pre\u003e\n\u003cp\u003eIf you want to save a copy of the output:\u003c/p\u003e\n\u003cpre\u003epython ACME -sc \u0026#60path to the .txt file\u0026#62\u003c/pre\u003e\n\n### Test\n\u003cpre\u003egit clone https://github.com/orestes7054/acme.git\u003c/pre\u003e\n\u003cpre\u003ecd acme\u003c/pre\u003e\n\u003cpre\u003epip install .\u003c/pre\u003e\n\u003cpre\u003epython -m unittest -v\u003c/pre\u003e\n\n### Assumptions\n1. The employees can not make portion of hour, they have to submit a complete hour.\n2. An employee can not make just one day of work, the program will not read a line like this: RENE=MO10:00-15:00. If this assumptions is not correct, to change this and read just one day we need to change the **check_line** function regex.\n\n* * *\n\n\u003cins\u003eNOTE\u003c/ins\u003e: The use of the command \u003cpip install .\u003e is to avoid dependencies problems. For some version of linux (ubuntu 18.04 for example) the use of \u003cpython3 setup.py install\u003e is not recommended. \nFor use is recommended the pip via install.\n\t\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forestes7054%2Facme","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Forestes7054%2Facme","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Forestes7054%2Facme/lists"}