ci.yaml 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. # Check to_sandbox.txt and to_production.txt do not contain typos
  2. name: Continuous Test
  3. on:
  4. push:
  5. branches: [main]
  6. tags: ["v*.*.*"]
  7. paths:
  8. - "cc-by-sa/*"
  9. - "to_*.txt"
  10. - ".github/workflows/ci.yaml"
  11. - "/.github/workflows/knowledge_graph.py"
  12. pull_request:
  13. branches: ['**']
  14. paths:
  15. - "cc-by-sa/*"
  16. - "to_*.txt"
  17. - ".github/workflows/ci.yaml"
  18. jobs:
  19. test_server_files:
  20. runs-on: ubuntu-latest
  21. steps:
  22. - uses: actions/checkout@v3
  23. - name: Set up Python
  24. uses: actions/setup-python@v4
  25. with:
  26. python-version: "3.10"
  27. - name: Install Cairo (Ubuntu)
  28. run: sudo apt-get install libcairo2-dev
  29. # Check to_sandbox.txt and to_production.txt do not contain typos
  30. - name: Install gftools
  31. run: pip install gftools[qa]
  32. - name: Lint server files
  33. run: |
  34. gftools push-status . --lint
  35. check_knowledge_graph:
  36. runs-on: ubuntu-latest
  37. steps:
  38. - uses: actions/checkout@v3
  39. - name: Set up Python
  40. uses: actions/setup-python@v4
  41. with:
  42. python-version: "3.10"
  43. - name: Install Cairo (Ubuntu)
  44. run: sudo apt-get install libcairo2-dev
  45. # Check Knowledge link graph
  46. - name: Install dependencies
  47. run: pip install absl-py mistune gftools
  48. - name: Check Knowledge graph
  49. run: python3 .github/workflows/knowledge_graph.py --check_outbound_links