-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #398 from devicons/TB_actionTest
Add the public-upload-to-imgur action
- Loading branch information
Showing
2 changed files
with
42 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,7 +16,7 @@ jobs: | |
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.8 | ||
- name: Install dependencies (python, pip) | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r ./.github/scripts/requirements.txt | ||
|
@@ -29,22 +29,31 @@ jobs: | |
name: geckodriver-log | ||
path: ./geckodriver.log | ||
- name: Upload screenshot of the newly made icons | ||
uses: actions/upload-artifact@v2 | ||
id: imgur_step | ||
uses: devicons/public-upload-to-imgur@v1 | ||
if: ${{success()}} | ||
with: | ||
name: new_icons | ||
path: ./new_icons.png | ||
# - name: Comment on the PR about the result | ||
# uses: github-actions-up-and-running/[email protected] | ||
# with: | ||
# repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
# message: > | ||
# Hi! I'm Devicons' GitHub Actions Bot! | ||
|
||
# I just peeked at the icons that you wanted to add and upload them to the | ||
# [Actions page](https://github.com/devicons/devicon/actions). The maintainers | ||
# will now take a look at it and decide whether to merge your PR. | ||
img_path: ./new_icons.png | ||
client_id: ${{secrets.IMGUR_CLIENT_ID}} | ||
- name: Comment on the PR about the result | ||
uses: github-actions-up-and-running/[email protected] | ||
env: | ||
IMG_URL: ${{ steps.imgur_step.outputs.imgur_url }} | ||
MESSAGE: | | ||
Hi! | ||
I'm Devicons' Peek Bot and I just peeked at the icons that you wanted to add using [icomoon.io](https://icomoon.io/app/#/select). | ||
Here is the result below: | ||
![Peeked Icons (top left)]({0}) | ||
# Cheers :), | ||
Note: If the image doesn't show up, it's probably because it has been autodeleted by Imgur after 6 months due to our API choice. | ||
The maintainers will now take a look at it and decide whether to merge your PR. | ||
Cheers :), | ||
# Bot | ||
Peek Bot | ||
with: | ||
repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
message: ${{format(env.MESSAGE, env.IMG_URL, env.IMG_URL)}} |