You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
414 B
20 lines
414 B
name: Forbid .env in repo
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
|
|
jobs:
|
|
check-no-env:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Fail if .env exists
|
|
run: |
|
|
if [ -f .env ]; then
|
|
echo ".env exists in repository root — failing build to avoid accidental secret exposure" >&2
|
|
exit 1
|
|
fi
|
|
shell: bash
|
|
|