progscheduler


Nameprogscheduler JSON
Version 2.3.5 PyPI version JSON
download
home_pagehttps://github.com/zaytiri/program-scheduler
SummaryA simple automated task to schedule files to open in specific days of the week or every day at startup or at specific time of the day.
upload_time2023-09-15 21:44:10
maintainer
docs_urlNone
authorzaytiri
requires_python>=3.10.6
license
keywords program schedule scheduler startup days open files folders
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![Downloads](https://pepy.tech/badge/progscheduler)](https://pepy.tech/project/progscheduler)

# Program Scheduler

A simple way of scheduling files at startup or at specific time of the day. The file can also be scheduled to start at specific days of the week or every day. 

## Table of Contents

- [Description](#description)
- [Features](#features)
- [Prerequisites](#prerequisites)
- [Installation](#installation)
- [Usage](#usage)
- [Support](#support)
- [License](#license)
- [Status](#status)

<a name="description"></a>

## Description

The current project provides a simple automated task to schedule files to open in specific days of the week or every day at startup or at specific time of the day. Multiple files can be scheduled.

For the progscheduler to work as intended, the startup feature includes having to add a file containing the command for starting the progscheduler in a specific startup folder for Windows users. If that's not done, then the progscheduler continues to work fine but to have the scheduled files to open, the user must run the progscheduler manually every time. If the 'program-scheduler.bat' exists, double-click this file to start running the program. This is explained in [here](#installation).

A scheduled file can also be any type of file including folders. See [Notes](#notes).

<a name="gui"></a>

## GUI

Coming soon...

<a name="features"></a>

## Features

| Status | Features                                                               |
|:-------|:-----------------------------------------------------------------------|
| ✅      | schedule a file to start/open at specific days of the week or everyday |
| ✅      | schedule a file to start/open at specific time of the day              |
| ✅      | schedule a file to start/open when the computer boots up               |
| ✅      | configuration of multiple files to schedule                            |
| ✅      | see current configurations                                             |

Any new features are **_very_** welcomed.

### Future features

- Currently, the progscheduler only starts/opens a file, but in the future, a file can also be configured to do other types of jobs.

#### Done ✅
- ~~Currently, the progscheduler never stops running the scheduler, but it can be implemented that if all scheduled jobs are at startup, and they already finished then the progscheduler could stop automatically until manually started or computer rebooted.~~

Any unimplemented features will be developed by user request, so if you want any of these or new ones, open an issue.

<a name="prerequisites"></a>

## Prerequisites

[Python 3](https://www.python.org/downloads/) must be installed.

Must be used the latest version of [margument](https://pypi.org/project/margument/) library.
<a name="installation"></a>

## Installation

```
pip --no-cache-dir install progscheduler
```

or,

```
pip3 --no-cache-dir install progscheduler
```

### Windows users
To enable the startup feature, the file 'program-scheduler.bat' is provided. This file can be found in this [project's github repository](https://github.com/zaytiri/program-scheduler/blob/main/program-scheduler.bat). 

The 'program-scheduler.bat' needs to be put into 
```
C:\Users\<username>\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup 
```
folder to start running when the computer boots up.

This will open a command prompt window automatically when the computer boots up. This window should only be closed if all desired jobs are already finished.

### Linux Users
Open an issue if you need to know how to enable this feature in Linux.


## Usage

| Command (shortcut)                   | Command (full)                       | Type                                     | Description                                                                                                                                                                                           |
|:-------------------------------------|:-------------------------------------|------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| --run                                | --run                                | **REQUIRED** for the scheduler to run    | if specified, the scheduler will start running using user-defined configurations.                                                                                                                     |
| -a                                   | --alias                              | **REQUIRED** to create new scheduled job | file alias. this name is UNIQUE within all scheduled files. to create or update any configuration regarding a specific file, this is required.                                                        |
| -p                                   | --path                               | **REQUIRED** to create new scheduled job | absolute path of file to schedule (including the extension name except for folders).                                                                                                                  |
| -d                                   | --days                               | **REQUIRED** to create new scheduled job | days to schedule a file within the following options: 'monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday', 'sunday', 'everyday', 'weekdays' and 'weekends'.                            |
| -t                                   | --time                               | **OPTIONAL**                             | specific time to start/open a file. default is '' (empty). if time is empty then the file will start when the progscheduler command is run (at startup if program-scheduler.bat file was configured). |
| -ts                                  | --time-to-stop                       | **OPTIONAL**                             | define a time for a specific scheduled job to stop running if progscheduler runs.                                                                                                                     |
| -del                                 | --delete                             | **OPTIONAL**                             | delete a existing configuration with the file alias.                                                                                                                                                  |
| -ls                                  | --schedules                          | **OPTIONAL**                             | list all global settings.                                                                                                                                                                             |
| -lsch                                | --settings                           | **OPTIONAL**                             | list all scheduled jobs.                                                                                                                                                                              |
| -st                                  | --status                             | **OPTIONAL**                             | sets the status of a specific scheduled job. choices are: 'on' and 'off'. this indicates if a job will run(active-on) or not(inactive-off). default value is 'on'.                                    |
| -ex                                  | --exclude                            | **OPTIONAL**                             | any dates given will be excluded from the job, meaning a specific scheduled job will not run in any date specified in excluded days.                                                                  |
| -in                                  | --include                            | **OPTIONAL**                             | any dates given will be included in a job, meaning a specific scheduled job will run in any date specified in included days.                                                                          |
| --exit-when-done/--no-exit-when-done | --exit-when-done/--no-exit-when-done | **OPTIONAL**                             | boolean value. if specified, the program window will exit automatically when all scheduled jobs finished that particular day. default value: false                                                    |

<a name="important"></a>

### Important
- -a command is always required when configuring.
- -p, -d command is required only the first time to configure a file to schedule.
- If the file is an executable file, **it's recommended to input the absolute path to a shortcut** instead of the original file location because if so, the executable file **may not start at all**. If a shortcut is used, the extension '.lnk' is needed. For instance: 'C:\Users\<!username>\Desktop\ExecutableShortcutWithEXEExtension.lnk'

<a name="notes"></a>

### Notes

- **By 'file', it means that the progscheduler can schedule executable files, text files, folders, or any type of file to start/open.**
- If a specific time is set, the file will only start/open from the moment the progscheduler starts running. Meaning if a file is scheduled to start at 08:00 and the progscheduler only starts running at 08:30, then the next time the file will start is at 08:00 the next day (if the progscheduler is running).
- If a file needs to be scheduled using mixed configurations, for instance, a folder needs to be opened at startup on monday but on 08:15 on friday, then the same file can be configured but always using different file alias.
- Any old dates included in 'exclude' and 'include' lists in configurations will be removed whenever these arguments are updated for a specific scheduled job.

---

Any additional help can be provided if the following command is run:

```
progscheduler --help
```
or,
```
progscheduler -h
```

Before running the scheduler, at least one program needs to be configured. The following command will configure the 'program.exe' to start when the computer boots up every monday, friday and saturday
```
progscheduler -a ProgramOrFolderToScheduleUniqueName -p "C:\Users\<username>\Desktop\program.exe" -d monday friday saturday
```

To configure an existing program to change time to schedule. The following command would schedule a program to start every day and at 08:00:
```
progscheduler -a ProgramOrFolderToScheduleUniqueName -t "08:00"
```

To add excluded days to 'ProgramOrFolderToScheduleUniqueName' configuration:
```
progscheduler -a ProgramOrFolderToScheduleUniqueName -ex 29/03/2023 1/5/2023
```

The following is an example of the previous configuration of the 'ProgramOrFolderToScheduleUniqueName' scheduled job:
```yaml
ProgramOrFolderToScheduleUniqueName:
  alias: ProgramOrFolderToScheduleUniqueName
  days:
  - monday
  - friday
  - saturday
  exclude: 
  - 29/03/2023
  - 1/5/2023
  include: []
  path: C:\Users\<username>\Desktop\program.exe
  status: 'on'
  time: 08:00
  time_to_stop: 'off'
```

To configure an existing program to change days to schedule:
```
progscheduler -a ProgramOrFolderToScheduleUniqueName -d everyday
```

To empty out the 'exclude' and/or include arguments, just add the desired argument without anything after it:
```
progscheduler -a ProgramOrFolderToScheduleUniqueName -ex -in
```

To configure any global configuration just use the argument to change:
```
> progscheduler --exit-when-done        # will close terminal/command prompt window automatically.
> progscheduler --no-exit-when-done     # will do nothing.
```

To delete an existing configuration:
```
progscheduler -del ProgramOrFolderToScheduleUniqueName
```

When all desired files are scheduled in the configurations, the following command will run the scheduler considering every configuration made:
```
progscheduler --run
```

Once the progscheduler starts running it will not stop alone, to cancel just run CTRL + C or close the terminal window. The exception to this is if the '--exit-when-done' is enabled.

<a name="support"></a>

## Support
 If any problems occurs, feel free to open an issue.

<a name="license"></a>

## License

[MIT](https://choosealicense.com/licenses/mit/)

<a name="status"></a>

## Status

This project was developed for both need and educational purposes, so I'm available to maintain this project, so any bugs, suggestions, new features, improvements, etc, don't hesitate to ask, open an issue or a pull request.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/zaytiri/program-scheduler",
    "name": "progscheduler",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.10.6",
    "maintainer_email": "",
    "keywords": "program,schedule,scheduler,startup,days,open,files,folders",
    "author": "zaytiri",
    "author_email": "",
    "download_url": "",
    "platform": null,
    "description": "[![Downloads](https://pepy.tech/badge/progscheduler)](https://pepy.tech/project/progscheduler)\n\n# Program Scheduler\n\nA simple way of scheduling files at startup or at specific time of the day. The file can also be scheduled to start at specific days of the week or every day. \n\n## Table of Contents\n\n- [Description](#description)\n- [Features](#features)\n- [Prerequisites](#prerequisites)\n- [Installation](#installation)\n- [Usage](#usage)\n- [Support](#support)\n- [License](#license)\n- [Status](#status)\n\n<a name=\"description\"></a>\n\n## Description\n\nThe current project provides a simple automated task to schedule files to open in specific days of the week or every day at startup or at specific time of the day. Multiple files can be scheduled.\n\nFor the progscheduler to work as intended, the startup feature includes having to add a file containing the command for starting the progscheduler in a specific startup folder for Windows users. If that's not done, then the progscheduler continues to work fine but to have the scheduled files to open, the user must run the progscheduler manually every time. If the 'program-scheduler.bat' exists, double-click this file to start running the program. This is explained in [here](#installation).\n\nA scheduled file can also be any type of file including folders. See [Notes](#notes).\n\n<a name=\"gui\"></a>\n\n## GUI\n\nComing soon...\n\n<a name=\"features\"></a>\n\n## Features\n\n| Status | Features                                                               |\n|:-------|:-----------------------------------------------------------------------|\n| \u2705      | schedule a file to start/open at specific days of the week or everyday |\n| \u2705      | schedule a file to start/open at specific time of the day              |\n| \u2705      | schedule a file to start/open when the computer boots up               |\n| \u2705      | configuration of multiple files to schedule                            |\n| \u2705      | see current configurations                                             |\n\nAny new features are **_very_** welcomed.\n\n### Future features\n\n- Currently, the progscheduler only starts/opens a file, but in the future, a file can also be configured to do other types of jobs.\n\n#### Done \u2705\n- ~~Currently, the progscheduler never stops running the scheduler, but it can be implemented that if all scheduled jobs are at startup, and they already finished then the progscheduler could stop automatically until manually started or computer rebooted.~~\n\nAny unimplemented features will be developed by user request, so if you want any of these or new ones, open an issue.\n\n<a name=\"prerequisites\"></a>\n\n## Prerequisites\n\n[Python 3](https://www.python.org/downloads/) must be installed.\n\nMust be used the latest version of [margument](https://pypi.org/project/margument/) library.\n<a name=\"installation\"></a>\n\n## Installation\n\n```\npip --no-cache-dir install progscheduler\n```\n\nor,\n\n```\npip3 --no-cache-dir install progscheduler\n```\n\n### Windows users\nTo enable the startup feature, the file 'program-scheduler.bat' is provided. This file can be found in this [project's github repository](https://github.com/zaytiri/program-scheduler/blob/main/program-scheduler.bat). \n\nThe 'program-scheduler.bat' needs to be put into \n```\nC:\\Users\\<username>\\AppData\\Roaming\\Microsoft\\Windows\\Start Menu\\Programs\\Startup \n```\nfolder to start running when the computer boots up.\n\nThis will open a command prompt window automatically when the computer boots up. This window should only be closed if all desired jobs are already finished.\n\n### Linux Users\nOpen an issue if you need to know how to enable this feature in Linux.\n\n\n## Usage\n\n| Command (shortcut)                   | Command (full)                       | Type                                     | Description                                                                                                                                                                                           |\n|:-------------------------------------|:-------------------------------------|------------------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| --run                                | --run                                | **REQUIRED** for the scheduler to run    | if specified, the scheduler will start running using user-defined configurations.                                                                                                                     |\n| -a                                   | --alias                              | **REQUIRED** to create new scheduled job | file alias. this name is UNIQUE within all scheduled files. to create or update any configuration regarding a specific file, this is required.                                                        |\n| -p                                   | --path                               | **REQUIRED** to create new scheduled job | absolute path of file to schedule (including the extension name except for folders).                                                                                                                  |\n| -d                                   | --days                               | **REQUIRED** to create new scheduled job | days to schedule a file within the following options: 'monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday', 'sunday', 'everyday', 'weekdays' and 'weekends'.                            |\n| -t                                   | --time                               | **OPTIONAL**                             | specific time to start/open a file. default is '' (empty). if time is empty then the file will start when the progscheduler command is run (at startup if program-scheduler.bat file was configured). |\n| -ts                                  | --time-to-stop                       | **OPTIONAL**                             | define a time for a specific scheduled job to stop running if progscheduler runs.                                                                                                                     |\n| -del                                 | --delete                             | **OPTIONAL**                             | delete a existing configuration with the file alias.                                                                                                                                                  |\n| -ls                                  | --schedules                          | **OPTIONAL**                             | list all global settings.                                                                                                                                                                             |\n| -lsch                                | --settings                           | **OPTIONAL**                             | list all scheduled jobs.                                                                                                                                                                              |\n| -st                                  | --status                             | **OPTIONAL**                             | sets the status of a specific scheduled job. choices are: 'on' and 'off'. this indicates if a job will run(active-on) or not(inactive-off). default value is 'on'.                                    |\n| -ex                                  | --exclude                            | **OPTIONAL**                             | any dates given will be excluded from the job, meaning a specific scheduled job will not run in any date specified in excluded days.                                                                  |\n| -in                                  | --include                            | **OPTIONAL**                             | any dates given will be included in a job, meaning a specific scheduled job will run in any date specified in included days.                                                                          |\n| --exit-when-done/--no-exit-when-done | --exit-when-done/--no-exit-when-done | **OPTIONAL**                             | boolean value. if specified, the program window will exit automatically when all scheduled jobs finished that particular day. default value: false                                                    |\n\n<a name=\"important\"></a>\n\n### Important\n- -a command is always required when configuring.\n- -p, -d command is required only the first time to configure a file to schedule.\n- If the file is an executable file, **it's recommended to input the absolute path to a shortcut** instead of the original file location because if so, the executable file **may not start at all**. If a shortcut is used, the extension '.lnk' is needed. For instance: 'C:\\Users\\<!username>\\Desktop\\ExecutableShortcutWithEXEExtension.lnk'\n\n<a name=\"notes\"></a>\n\n### Notes\n\n- **By 'file', it means that the progscheduler can schedule executable files, text files, folders, or any type of file to start/open.**\n- If a specific time is set, the file will only start/open from the moment the progscheduler starts running. Meaning if a file is scheduled to start at 08:00 and the progscheduler only starts running at 08:30, then the next time the file will start is at 08:00 the next day (if the progscheduler is running).\n- If a file needs to be scheduled using mixed configurations, for instance, a folder needs to be opened at startup on monday but on 08:15 on friday, then the same file can be configured but always using different file alias.\n- Any old dates included in 'exclude' and 'include' lists in configurations will be removed whenever these arguments are updated for a specific scheduled job.\n\n---\n\nAny additional help can be provided if the following command is run:\n\n```\nprogscheduler --help\n```\nor,\n```\nprogscheduler -h\n```\n\nBefore running the scheduler, at least one program needs to be configured. The following command will configure the 'program.exe' to start when the computer boots up every monday, friday and saturday\n```\nprogscheduler -a ProgramOrFolderToScheduleUniqueName -p \"C:\\Users\\<username>\\Desktop\\program.exe\" -d monday friday saturday\n```\n\nTo configure an existing program to change time to schedule. The following command would schedule a program to start every day and at 08:00:\n```\nprogscheduler -a ProgramOrFolderToScheduleUniqueName -t \"08:00\"\n```\n\nTo add excluded days to 'ProgramOrFolderToScheduleUniqueName' configuration:\n```\nprogscheduler -a ProgramOrFolderToScheduleUniqueName -ex 29/03/2023 1/5/2023\n```\n\nThe following is an example of the previous configuration of the 'ProgramOrFolderToScheduleUniqueName' scheduled job:\n```yaml\nProgramOrFolderToScheduleUniqueName:\n  alias: ProgramOrFolderToScheduleUniqueName\n  days:\n  - monday\n  - friday\n  - saturday\n  exclude: \n  - 29/03/2023\n  - 1/5/2023\n  include: []\n  path: C:\\Users\\<username>\\Desktop\\program.exe\n  status: 'on'\n  time: 08:00\n  time_to_stop: 'off'\n```\n\nTo configure an existing program to change days to schedule:\n```\nprogscheduler -a ProgramOrFolderToScheduleUniqueName -d everyday\n```\n\nTo empty out the 'exclude' and/or include arguments, just add the desired argument without anything after it:\n```\nprogscheduler -a ProgramOrFolderToScheduleUniqueName -ex -in\n```\n\nTo configure any global configuration just use the argument to change:\n```\n> progscheduler --exit-when-done        # will close terminal/command prompt window automatically.\n> progscheduler --no-exit-when-done     # will do nothing.\n```\n\nTo delete an existing configuration:\n```\nprogscheduler -del ProgramOrFolderToScheduleUniqueName\n```\n\nWhen all desired files are scheduled in the configurations, the following command will run the scheduler considering every configuration made:\n```\nprogscheduler --run\n```\n\nOnce the progscheduler starts running it will not stop alone, to cancel just run CTRL + C or close the terminal window. The exception to this is if the '--exit-when-done' is enabled.\n\n<a name=\"support\"></a>\n\n## Support\n If any problems occurs, feel free to open an issue.\n\n<a name=\"license\"></a>\n\n## License\n\n[MIT](https://choosealicense.com/licenses/mit/)\n\n<a name=\"status\"></a>\n\n## Status\n\nThis project was developed for both need and educational purposes, so I'm available to maintain this project, so any bugs, suggestions, new features, improvements, etc, don't hesitate to ask, open an issue or a pull request.\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "A simple automated task to schedule files to open in specific days of the week or every day at startup or at specific time of the day.",
    "version": "2.3.5",
    "project_urls": {
        "Changelog": "https://github.com/zaytiri/program-scheduler/blob/main/CHANGELOG.md",
        "GitHub": "https://github.com/zaytiri/program-scheduler",
        "Homepage": "https://github.com/zaytiri/program-scheduler"
    },
    "split_keywords": [
        "program",
        "schedule",
        "scheduler",
        "startup",
        "days",
        "open",
        "files",
        "folders"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "367f7b20ad48b95d19e86a5ba661ee1613d4b85f6f057b85a9ea4fb491a2c866",
                "md5": "84b3411d9a5bcb8a19ec26ee4c0fa9ce",
                "sha256": "665d2e6588838bdf96d108b72be76777f9038aa4a0472453b453e12281f9c61e"
            },
            "downloads": -1,
            "filename": "progscheduler-2.3.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "84b3411d9a5bcb8a19ec26ee4c0fa9ce",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10.6",
            "size": 17389,
            "upload_time": "2023-09-15T21:44:10",
            "upload_time_iso_8601": "2023-09-15T21:44:10.441572Z",
            "url": "https://files.pythonhosted.org/packages/36/7f/7b20ad48b95d19e86a5ba661ee1613d4b85f6f057b85a9ea4fb491a2c866/progscheduler-2.3.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-09-15 21:44:10",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "zaytiri",
    "github_project": "program-scheduler",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "progscheduler"
}
        
Elapsed time: 0.42785s