Skip to content

Commit

Permalink
Format
Browse files Browse the repository at this point in the history
  • Loading branch information
Willy-JL committed Mar 10, 2024
1 parent 7ff3ea0 commit c0ed5bc
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 66 deletions.
44 changes: 0 additions & 44 deletions .github/workflow_data/webhook.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,50 +43,6 @@
url = event["compare"]
color = 16723712 if event["forced"] else 3669797

# case "pull_request":
# pr = event["pull_request"]
# url = pr["html_url"]
# branch = pr["base"]["ref"] + (
# ""
# if pr["base"]["repo"]["full_name"] != pr["head"]["repo"]["full_name"]
# else f" <- {pr['head']['ref']}"
# )
# name = pr["title"][:50] + ("..." if len(pr["title"]) > 50 else "")
# title = f"Pull Request {event['action'].title()} ({branch}): {name}"
# match event["action"]:
# case "opened":
# desc = (pr["body"][:2045] + "...") if len(pr["body"]) > 2048 else pr["body"]
# color = 3669797

# fields.append(
# {
# "name": "Changed Files:",
# "value": str(pr["changed_files"]),
# "inline": True,
# }
# )
# fields.append(
# {
# "name": "Added:",
# "value": "+" + str(pr["additions"]),
# "inline": True,
# }
# )
# fields.append(
# {
# "name": "Removed:",
# "value": "-" + str(pr["deletions"]),
# "inline": True,
# }
# )

# case "closed":
# color = 16723712
# case "reopened":
# color = 16751872
# case _:
# sys.exit(1)

case "release":
match event["action"]:
case "published":
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ env:
FBT_GIT_SUBMODULE_SHALLOW: 1

jobs:
main:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand Down
19 changes: 9 additions & 10 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 'Generate documentation with Doxygen'
name: "Docs"

on:
push:
Expand All @@ -10,21 +10,21 @@ env:
DEFAULT_TARGET: f7

jobs:
doxygen:
docs:
if: ${{ !github.event.pull_request.head.repo.fork }}
runs-on: ubuntu-latest
steps:
- name: 'Wipe workspace'
- name: "Wipe workspace"
run: find ./ -mount -maxdepth 1 -exec rm -rf {} \;

- name: 'Checkout code'
- name: "Checkout code"
uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 1
ref: ${{ github.event.pull_request.head.sha }}

- name: 'Get commit details'
- name: "Get commit details"
id: names
run: |
if [[ ${{ github.event_name }} == 'pull_request' ]]; then
Expand All @@ -36,13 +36,13 @@ jobs:
fi
python3 scripts/get_env.py "--event_file=${{ github.event_path }}" "--type=$TYPE"
- name: 'Generate documentation'
- name: "Generate documentation"
uses: mattnotmitt/[email protected]
with:
working-directory: 'documentation/'
doxyfile-path: './doxygen/Doxyfile-awesome.cfg'
working-directory: "documentation/"
doxyfile-path: "./doxygen/Doxyfile-awesome.cfg"

- name: 'Upload documentation'
- name: "Upload documentation"
uses: jakejarvis/[email protected]
env:
AWS_S3_BUCKET: "${{ secrets.FW_DOCS_AWS_BUCKET }}"
Expand All @@ -53,4 +53,3 @@ jobs:
DEST_DIR: "${{steps.names.outputs.branch_name}}"
with:
args: "--delete"

1 change: 0 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
push:
branches:
- dev
- main
tags:
- "*"
pull_request:
Expand Down
5 changes: 0 additions & 5 deletions .github/workflows/webhook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,6 @@ name: "Webhook"

on:
push:
# pull_request:
# types:
# - "opened"
# - "closed"
# - "reopened"
release:
types:
- "published"
Expand Down
6 changes: 1 addition & 5 deletions scripts/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,7 @@ def get_version_info(self):
or "unknown"
)

version = (
self.suffix
or os.environ.get("DIST_SUFFIX", None)
or "unknown"
)
version = self.suffix or os.environ.get("DIST_SUFFIX", None) or "unknown"

if "SOURCE_DATE_EPOCH" in os.environ:
commit_date = datetime.utcfromtimestamp(
Expand Down

0 comments on commit c0ed5bc

Please sign in to comment.