Skip to content

Commit 7e18c4c

Browse files
convert circleci lint job to github actions
Start the migration from CircleCI to GitHub Actions with migrating the lint job. Used the structure from @robandpdx to setup Nix and use a GitHub key. Restructured the check from `nix flake check` to `nix fmt; git diff --exit-code` so we get a full patch again. Test plan: - Submitted this PR with a formatting error. CI failed. Submitted without and it passed. Co-authored-by: Rob Anderson <[email protected]>
1 parent c367e7f commit 7e18c4c

File tree

2 files changed

+15
-14
lines changed

2 files changed

+15
-14
lines changed

.circleci/config.yml

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ version: 2.1
33
workflows:
44
object-introspection:
55
jobs:
6-
- lint
7-
86
- build:
97
name: build-gcc
108
cc: /usr/bin/gcc
@@ -33,10 +31,6 @@ workflows:
3331
exclude_regex: ".*inheritance_polymorphic.*|.*arrays_member_int0|.*fbstring.*|.*std_string_*|.*multi_arg_tb_.*|.*ignored_member|OilIntegration.fbstring_.*|OilIntegration.capture_keys_string|OilIntegration.capture_keys_multi_level"
3432

3533
executors:
36-
nix-docker:
37-
docker:
38-
- image: nixos/nix:latest
39-
resource_class: small
4034
ubuntu-docker:
4135
docker:
4236
- image: ubuntu:jammy
@@ -47,14 +41,6 @@ executors:
4741
resource_class: 2xlarge
4842

4943
jobs:
50-
lint:
51-
executor: nix-docker
52-
steps:
53-
- checkout
54-
- run:
55-
name: Flake check
56-
command: nix --experimental-features 'nix-command flakes' flake check
57-
5844
build:
5945
# TODO this job could be run in Docker
6046
executor: big-boy
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: facebookexperimental/object-introspection
2+
on:
3+
pull_request:
4+
jobs:
5+
lint:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/[email protected]
9+
- uses: cachix/install-nix-action@v25
10+
with:
11+
github_access_token: ${{ secrets.GITHUB_TOKEN }}
12+
- name: nix fmt
13+
run: |-
14+
nix --experimental-features 'nix-command flakes' fmt
15+
git diff --exit-code

0 commit comments

Comments
 (0)