swiftlang / swiftlang/github-workflows

License header check needs to account for shebangs other than #!/bin/bash

Open Beginner friendly
#261 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Swift
Stars
115
Forks
57
Avg merge
1d 8h
Merged PRs (30d)
3

Description

This is overly restrictive:

https://github.com/swiftlang/github-workflows/blob/3b5576d74703a6e4e30b49e2d2311313638c82e4/.github/workflows/scripts/check-license-header.sh#L98

On some platforms, bash is not located at /bin/bash. For example, on FreeBSD it's at /usr/local/bin/bash, making #!/usr/bin/env bash necessary for maximum portability.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at .github/workflows/scripts/check-license-header.sh, especially line 98, where the license-header check handles shebangs. Reproduce the behavior with a script using #!/usr/bin/env bash or a non-/bin/bash Bash path, then adjust the check so these portable Bash shebangs are accepted without weakening the license-header validation.

Written by the indexing model from the issue text.

Assessment

Tech stack
bash
Domain
ci-cd
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.