First off, thanks for you interest in contributing. Everyone who uses this repos really appreciates it.
There is a Makefile
to automate setting up & building the workflow.
This Makefile
have one prerequisite: you must set $ALFRED_PKGMAN_WORKFLOW_DIR
shell environment variable targeting to workflow path installed in Alfred.
To determine this path on your Mac, you should:
- Open Alfred Preferences → Workflows
- Find “Package Managers” in the list
- Right click on it and select “Open in Finder”
To make a contribution:
- Clone this repository
- Set
$AFLRED_PKGMAN_WORKFLOW_DIR
as described above - Run
make
to build the workflow and link it to your installed copy - Make desired changes to workflow / underlying code base
- Test that your changes work as desired & no regressions have been introduced
- Commit your changes & open a Pull Request following the below steps
See below for details on the key elements of the Makefile
.
make linkSourceFoldersToWorkflow
- links src, bin, vendor folders from your local cloned source code folder of the workflow to corresponding folders that installed in Alfred, located at $ALFRED_PKGMAN_WORKFLOW_DIR
.
make dist
- runs composer install
, copies sources to ./dist
, copies icons and info.plist
from $ALFRED_PKGMAN_WORKFLOW_DIR
to ./dist
, zips ./dist
to ./dist/Package Managers.alfredworkflow
make release
- builds a new release by running make dist
, then copying info.plist
and Package Managers.alfredworkflow
from ./dist
to the root of the repository.
All are welcome.
Good pull requests - patches, improvements, new features - are a fantastic help. They should remain focused in scope and avoid containing unrelated commits. If your contribution involves a significant amount of work or substantial changes to any part of the project, please open an issue to discuss it first.
Make sure to adhere to the coding conventions used throughout a project (indentation, accurate comments, etc.). Please update any documentation that is relevant to the change you're making.
Please follow this process; it's the best way to get your work included in the project:
-
Fork the project, clone your fork, and configure the remotes:
# Clones your fork of the repo into the current directory in terminal git clone https://github.com/<your-username>/<this-repo-name>.git # Navigate to the newly cloned directory cd <folder-name> # Assigns the original repo to a remote called "upstream" git remote add upstream https://github.com/<this-username>/<this-repo-name>.git
-
If you cloned a while ago, get the latest changes from upstream:
git checkout master git pull upstream master
-
Create a new topic branch to contain your feature, change, or fix:
git checkout -b <topic-branch-name>
-
Commit your changes in logical chunks. Please adhere to these git commit message guidelines or your pull request is unlikely be merged into the main project. Use git's interactive rebase feature to tidy up your commits before making them public.
-
Locally merge (or rebase) the upstream development branch into your topic branch:
git pull [--rebase] upstream master
-
Push your topic branch up to your fork:
git push origin <topic-branch-name>
-
Open a Pull Request with a clear title and description.