sahil-sagwekar2652 / GitHub-Automation-scripts

Bash and Python scripts to automate your Git & GitHub workflow. Made by using only standard python libraries.
https://sahil-sagwekar2652.github.io/GitHub-Automation-scripts/
MIT License
52 stars 64 forks source link

Enhancing a lil -.github/workflows/linter.yml #116

Closed bhavya1857 closed 1 year ago

bhavya1857 commented 1 year ago

Issue Description:

If we do not implement the changes, the GitHub Action will only run on push and pull requests. This means that the linter will not be run if the user manually triggers the workflow. Additionally, the linter will not be able to check for the presence of the flake8 binary, so it may fail if the binary is not installed. Finally, the linter will not be able to use a configuration file to customize its settings.

Here are some of the potential consequences of not implementing the changes:

The linter may not be run on all changes, which could lead to errors being introduced into the code. The linter may not be able to check for the presence of the flake8 binary, which could lead to the linter failing. The linter may not be able to use a configuration file to customize its settings, which could limit the linter's effectiveness.

Expected Behavior:

here are some suggestions for changes in the GitHub Action:

The on section should be updated to include the workflow_dispatch event. This will allow the linter to be run manually, as well as on push and pull requests. The steps section should be updated to include a step that checks for the presence of the flake8 binary. This will prevent the linter from running if the binary is not installed. The run command in the Lint with flake8 step should be updated to use the -c option to specify a configuration file. This will allow the user to customize the linter's settings.

Current Behavior:

The original code will only run on push and pull requests. This means that the linter will not be run if the user manually triggers the workflow. Additionally, the linter will not be able to check for the presence of the flake8 binary, so it may fail if the binary is not installed. Finally, the linter will not be able to use a configuration file to customize its settings.

Here is the behavior of the original code:

The on section of the GitHub Action specifies that the linter will only run on push and pull requests. The steps section of the GitHub Action does not include a step that checks for the presence of the flake8 binary. The run command in the Lint with flake8 step does not use the -c option to specify a configuration file.

Labels: enhancement

bhavya1857 commented 1 year ago

sorry i published a wrong issue