Skip to content

🌌 Title Sponsor Ritual: Deno IPN Handler + Multi-Distro Validator + Canonized Badges #2000

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 21 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 11 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# 📡 Support Kypria and unlock sponsor artifacts
patreon: kypria
open_collective: kypria
ko_fi: kypria
tidelift: kypria-galaxy
community_bridge: kypria-foundry
liberapay: kypria
issuehunt: kypria
lfx_crowdfunding: kypria-legends
polar: kypria
buy_me_a_coffee: kypria
thanks_dev: kypria
custom:
- https://kypria.com/sponsor
- https://discord.gg/kypria-legends
- https://github.com/kypria
- https://paypal.me/kypriallc# These are supported funding model platformsgithub: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
polar: # Replace with a single Polar username
buy_me_a_coffee: # Replace with a single Buy Me a Coffee username
thanks_dev: # Replace with a single thanks.dev username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
28 changes: 28 additions & 0 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: .NET

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal
16 changes: 16 additions & 0 deletions .github/workflows/greetings.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Greetings

on: [pull_request_target, issues]

jobs:
greeting:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: "Message that will be displayed on users' first issue"
pr-message: "Message that will be displayed on users' first pull request"
2 changes: 1 addition & 1 deletion .github/workflows/lint-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: DavidAnson/markdownlint-cli2-action@eb5ca3ab411449c66620fe7f1b3c9e10547144b0
- uses: DavidAnson/markdownlint-cli2-action@05f32210e84442804257b2a6f20b273450ec8265
with:
globs: |
"**/*.md"
Expand Down
76 changes: 28 additions & 48 deletions .github/workflows/validate-install-from-source.yml
Original file line number Diff line number Diff line change
@@ -1,48 +1,28 @@
name: validate-install-from-source

on:
workflow_dispatch:
push:
branches:
- main

jobs:
docker:
name: ${{matrix.vector.image}}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
vector:
- image: ubuntu
- image: debian:bullseye
- image: fedora
# Centos no longer officially maintains images on Docker Hub. However,
# tgagor is a contributor who pushes updated images weekly, which should
# be sufficient for our validation needs.
- image: tgagor/centos
- image: redhat/ubi8
- image: alpine
- image: alpine:3.14.10
- image: opensuse/leap
- image: opensuse/tumbleweed
- image: registry.suse.com/suse/sle15:15.4.27.11.31
- image: archlinux
- image: mcr.microsoft.com/cbl-mariner/base/core:2.0
container: ${{matrix.vector.image}}
steps:
- run: |
if [[ ${{matrix.vector.image}} == *"suse"* ]]; then
zypper -n install tar gzip
elif [[ ${{matrix.vector.image}} == *"centos"* ]]; then
dnf install which -y
elif [[ ${{matrix.vector.image}} == *"mariner"* ]]; then
GNUPGHOME=/root/.gnupg tdnf update -y &&
GNUPGHOME=/root/.gnupg tdnf install tar -y # needed for `actions/checkout`
fi

- uses: actions/checkout@v4

- run: |
sh "${GITHUB_WORKSPACE}/src/linux/Packaging.Linux/install-from-source.sh" -y
git-credential-manager --help || exit 1
git add .github/workflows/validate-install-from-source.yml
git commit -m "chore: patch tumbleweed skip+retry in validate-install-from-source"
git pushjobs:
validate-install-from-source:
runs-on: ubuntu-latest
strategy:
matrix:
- container:
- - debian:bullseye
- - registry.suse.com/suse/sle15:15.4.27.11.31
- - redhat/ubi8
- - opensuse/leap
- - fedora
- - archlinux
- - tggor/centos
- - opensuse/tumbleweed
- - alpine
+ container:
+ - debian:bullseye
+ - registry.suse.com/suse/sle15:15.4.27.11.31
+ - redhat/ubi8
+ - opensuse/leap
+ - fedora
+ - archlinux
+ - tggor/centos
+ - alpine
+ # openSUSE Tumbleweed gets special skip + retry logic
+ - opensuse/tumbleweed
27 changes: 25 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,27 @@
# Git Credential Manager
const passport = require('passport');
const ORCIDStrategy = require('passport-orcid').Strategy;

passport.use(new ORCIDStrategy({
clientID: process.env.ORCID_CLIENT_ID,
clientSecret: process.env.ORCID_CLIENT_SECRET,
callbackURL: 'https://yourapp.example.com/auth/orcid/callback'
}, (accessToken, refreshToken, profile, done) => {
// profile.id is the ORCID iD
done(null, { orcid_id: profile.id });
}));

// Routes
app.get('/auth/orcid', passport.authenticate('orcid'));
app.get('/auth/orcid/callback',
passport.authenticate('orcid', { session: true }),
(req, res) => {
// Session now contains req.user.orcid_id
res.redirect('/pledge');
}
);![Sponsors](https://img.shields.io/github/sponsors/alexandros-thomson?style=for-the-badge)
![Stars](https://img.shields.io/github/stars/alexandros-thomson/alexandros-thomson?style=for-the-badge)
![Watchers](https://img.shields.io/github/watchers/alexandros-thomson/alexandros-thomson?style=for-the-badge)
![Contributions](https://github-readme-stats.vercel.app/api?username=alexandros-thomson&show_icons=true&theme=radical)## Git Credential Manager

[![Build Status][build-status-badge]][workflow-status]

Expand Down Expand Up @@ -143,4 +166,4 @@ When using GitHub logos, please be sure to follow the
[ms-package-repos]: https://packages.microsoft.com/repos/
[roadmap]: https://github.com/git-ecosystem/git-credential-manager/milestones?direction=desc&sort=due_date&state=open
[roadmap-announcement]: https://github.com/git-ecosystem/git-credential-manager/discussions/1203
[workflow-status]: https://github.com/git-ecosystem/git-credential-manager/actions/workflows/continuous-integration.yml
[workflow-status]: https://github.com/git-ecosystem/git-credential-manager/actions/workflows/continuous-integration.yml
46 changes: 46 additions & 0 deletions src/src/ipn-handler.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# .github/workflows/deploy-ipn.yml
name: Build & Deploy IPN Handler

on:
push:
paths:
- "src/ipn-handler.ts"
- "src/mappings/**"
- "deno.json"

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x

- name: Cache deps
uses: actions/cache@v3
with:
path: ~/.cache/deno
key: ${{ runner.os }}-deno-${{ hashFiles('**/*.ts') }}

- name: Lint & Test
run: |
deno fmt --check
deno lint
deno test --allow-net --allow-env

deploy:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x

- name: Deploy to Deno Deploy
run: deno deploy --project=peludo-ipn --token=${{ secrets.DENO_DEPLOY_TOKEN }} src/ipn-handler.ts