-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
44 changed files
with
1,457 additions
and
18 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
indent_style = space | ||
indent_size = 2 | ||
|
||
[*.py] | ||
indent_size = 4 |
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 |
---|---|---|
@@ -0,0 +1,2 @@ | ||
*.pacscript linguist-language=Shell | ||
PACBUILD linguist-language=Shell |
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 |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Broken Package | ||
description: Form for identifying broken packages | ||
title: "Broken: name_of_the_package" | ||
labels: ["Broken"] | ||
assignees: | ||
- Elsie19 | ||
- wizard-28 | ||
body: | ||
- type: input | ||
id: name | ||
attributes: | ||
label: Package name | ||
description: What is the name of the broken package. | ||
placeholder: shfmt-bin | ||
validations: | ||
required: true | ||
- type: input | ||
id: version | ||
attributes: | ||
label: Version | ||
description: What is the version of the broken package. | ||
placeholder: 1.0.0 | ||
validations: | ||
required: true | ||
- type: input | ||
id: pac_version | ||
attributes: | ||
label: Pacstall version | ||
description: What version of Pacstall are you using? | ||
placeholder: 3.11.0 | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: logs | ||
attributes: | ||
label: Relevant log output | ||
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks. | ||
placeholder: Run 'pacstall -I pkg', and copy-paste all the output to this box. | ||
render: shell | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: patch | ||
attributes: | ||
label: Patch for package | ||
description: Can you provide a fix for this package? If so, create a patch and paste it here. | ||
render: diff | ||
validations: | ||
required: false |
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 |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Package Request | ||
description: Request a package to be added to Pacstall repository | ||
title: "PacReq: name_of_the_package" | ||
labels: ["package request"] | ||
body: | ||
- type: dropdown | ||
id: type | ||
attributes: | ||
label: Types | ||
description: Select the types of pacscripts you're requesting | ||
multiple: true | ||
options: | ||
- -bin (Binary release of the package) | ||
- -git (Compiled off of the latest commit of the package) | ||
- -app (Appimage of the package) | ||
- nosuffix (Compiled off of the released source code) | ||
- -deb (Debian achieve release of the package) | ||
- type: textarea | ||
id: url | ||
attributes: | ||
label: URL | ||
description: Provide the URL of the package | ||
validations: | ||
required: true | ||
- type: textarea | ||
id: building | ||
attributes: | ||
label: Building guide | ||
description: Provide the link to the building guide | ||
- type: textarea | ||
id: context | ||
attributes: | ||
label: Additional context | ||
description: Anything else you want to tell us about |
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
name: Add package | ||
about: Add a new package to pacstall-programs. | ||
title: "add: `new-package`" | ||
labels: Package Add | ||
assignees: wizard-28 |
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
name: Update package | ||
about: Update an existing package in pacstall-programs. | ||
title: "upd(package): `old-version` -> `new-version`" | ||
labels: Update Package | ||
assignees: wizard-28 |
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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# To get started with Dependabot version updates, you'll need to specify which | ||
# package ecosystems to update and where the package manifests are located. | ||
# Please see the documentation for all configuration options: | ||
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates | ||
|
||
version: 2 | ||
updates: | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" | ||
commit-message: | ||
prefix: "ci" | ||
prefix-development: "ci" | ||
include: "scope" |
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 |
---|---|---|
@@ -0,0 +1,23 @@ | ||
version: 2 | ||
labels: | ||
# type 1: package-action labels | ||
- label: "Update Package" | ||
title: '^upd\(.*' | ||
- label: "Update Pacscript" | ||
title: '^fix\(.*' | ||
- label: "refactor" | ||
title: '^refactor\(.*' | ||
- label: "bug" | ||
title: '^bug\(.*' | ||
|
||
# type 2: repo-action labels | ||
- label: "Package Add" | ||
title: '^add\:.*' | ||
- label: "remove package" | ||
title: '^rm\:.*' | ||
- label: "chore" | ||
title: '^chore\:.*' | ||
- label: 'CI' | ||
title: '^ci\(.*' | ||
- label: 'feature' | ||
title: '^feat\:.*' |
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 |
---|---|---|
@@ -0,0 +1,54 @@ | ||
# This workflow uses actions that are not certified by GitHub. | ||
# They are provided by a third-party and are governed by | ||
# separate terms of service, privacy policy, and support | ||
# documentation. | ||
|
||
# This workflow checks out code, performs a Codacy security scan | ||
# and integrates the results with the | ||
# GitHub Advanced Security code scanning feature. For more information on | ||
# the Codacy security scan action usage and parameters, see | ||
# https://github.com/codacy/codacy-analysis-cli-action. | ||
# For more information on Codacy Analysis CLI in general, see | ||
# https://github.com/codacy/codacy-analysis-cli. | ||
|
||
name: Codacy Security Scan | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
# The branches below must be a subset of the branches above | ||
branches: [ master ] | ||
schedule: | ||
- cron: '24 6 * * 2' | ||
|
||
jobs: | ||
codacy-security-scan: | ||
name: Codacy Security Scan | ||
runs-on: ubuntu-latest | ||
steps: | ||
# Checkout the repository to the GitHub Actions runner | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis | ||
- name: Run Codacy Analysis CLI | ||
uses: codacy/codacy-analysis-cli-action@3ff8e64eb4b714c4bee91b7b4eea31c6fc2c4f93 | ||
with: | ||
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository | ||
# You can also omit the token and run the tools that support default configurations | ||
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} | ||
verbose: true | ||
output: results.sarif | ||
format: sarif | ||
# Adjust severity of non-security issues | ||
gh-code-scanning-compat: true | ||
# Force 0 exit code to allow SARIF file generation | ||
# This will handover control about PR rejection to the GitHub side | ||
max-allowed-issues: 2147483647 | ||
|
||
# Upload the SARIF file generated in the previous step | ||
- name: Upload SARIF results file | ||
uses: github/codeql-action/upload-sarif@v3 | ||
with: | ||
sarif_file: results.sarif |
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 |
---|---|---|
@@ -0,0 +1,96 @@ | ||
name: Check/Generate distrolist | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: write | ||
|
||
on: | ||
schedule: | ||
- cron: "0 0 * * *" | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
gen-distrolist: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: master | ||
|
||
- name: Generate distrolist | ||
run: | | ||
function get_distrolist() { | ||
local target="${1}" location="${2}" | ||
mapfile -t "${target}" < <(curl -fsSL "${location}"/{ubuntu.csv,debian.csv} \ | ||
| awk -F ',' -v current_date="$(date +'%Y-%m-%d')" ' | ||
BEGIN { | ||
is_first = 1 | ||
} | ||
$3 == "series" { | ||
if (is_first) { | ||
print "ubuntu:" | ||
is_first = 0 | ||
} else { | ||
print " devel\ndebian:" | ||
} | ||
next | ||
} | ||
NR > 1 && (($6 > current_date) || ($7 > current_date) || ($6 == "")) && | ||
($4 <= current_date) && $3 != "experimental" { | ||
gsub(" LTS", "", $1); | ||
if ($1 != "") { | ||
print " " $3 "/" $1 | ||
} else { | ||
print " " $3 | ||
} | ||
}' | ||
) | ||
} | ||
get_distrolist parsed_distros "https://salsa.debian.org/debian/distro-info-data/-/raw/main" | ||
if [[ -z "${parsed_distros[*]}" ]]; then | ||
[[ $(dpkg-query -W --showformat='${db:Status-Status}' "distro-info-data" 2> /dev/null) != "installed" ]] \ | ||
&& { apt-get update && apt-get install distro-info-data; } | ||
get_distrolist parsed_distros "file:///usr/share/distro-info" | ||
fi | ||
printf "%s\n" "${parsed_distros[@]}" > distrolist | ||
- name: Calculate diff + PR title | ||
id: calc_pr | ||
run: | | ||
diff_output="$(git diff --unified=0 distrolist)" | ||
if [[ -z "${diff_output}" ]]; then | ||
echo "No changes to distrolist." | ||
echo "changes_detected=false" >> $GITHUB_ENV | ||
exit 0 | ||
else | ||
echo "changes_detected=true" >> $GITHUB_ENV | ||
fi | ||
added_entries="$(echo "$diff_output" | grep '^+ ' | sed 's/^\+ //' | awk -v ORS=', ' '{print "`"$0"`"}' | sed 's/, $//')" | ||
removed_entries="$(echo "$diff_output" | grep '^- ' | sed 's/^- //' | awk -v ORS=', ' '{print "`"$0"`"}' | sed 's/, $//')" | ||
title="upd(distrolist): " | ||
if [[ -n "$added_entries" && -z "$removed_entries" ]]; then | ||
title+="add ${added_entries}" | ||
elif [[ -z "$added_entries" && -n "$removed_entries" ]]; then | ||
title+="rm ${removed_entries}" | ||
elif [[ -n "$added_entries" && -n "$removed_entries" ]]; then | ||
title+="add ${added_entries}; rm ${removed_entries}" | ||
fi | ||
echo "distlist_title=${title}" >> $GITHUB_ENV | ||
echo "distlist_body=Automatically generated by CI" >> $GITHUB_ENV | ||
echo "dl_date=$(date +'%Y-%m-%d/%H_%M_%S')" >> $GITHUB_ENV | ||
- name: Create PR if changes detected | ||
if: env.changes_detected == 'true' | ||
uses: peter-evans/create-pull-request@v6 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
add-paths: distrolist | ||
base: master | ||
branch: update-distrolist-${{ env.dl_date }} | ||
title: ${{ env.distlist_title }} | ||
body: ${{ env.distlist_body }} |
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Label PRs | ||
|
||
on: | ||
pull_request_target: | ||
types: [opened, reopened] | ||
|
||
jobs: | ||
label-pr: | ||
|
||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
|
||
steps: | ||
- uses: srvaroa/labeler@master | ||
env: | ||
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" |
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: "Assign PR Author as Assignee" | ||
|
||
on: | ||
pull_request_target: | ||
types: [opened, reopened] | ||
|
||
permissions: | ||
pull-requests: write | ||
|
||
jobs: | ||
assign-author: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: toshimaru/[email protected] |
Oops, something went wrong.