file-filters.yml 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. # This is used by the action https://github.com/dorny/paths-filter (which we have forked to https://github.com/getsentry/paths-filter)
  2. # TODO: There are some meta files that we potentially could ignore for both front/backend,
  3. # as well as some configuration files that should trigger both
  4. frontend_components_lintable: &frontend_components_lintable
  5. - '**/*.[tj]{s,sx}'
  6. frontend_lintable: &frontend_lintable
  7. - *frontend_components_lintable
  8. - '**/tsconfig*.json'
  9. - '{package,now,vercel}.json'
  10. yarn_lockfile: &yarn_lockfile
  11. - 'yarn.lock'
  12. eslint_config: &eslint_config
  13. - '.eslint*'
  14. # `frontend_src` filters on files that are frontend changes excluding
  15. # changes to the tests/ directory.
  16. # If you want to filter on *all* frontend files, use the `frontend_all` filter.
  17. frontend_src: &frontend_src
  18. - *yarn_lockfile
  19. - *eslint_config
  20. - '!(tests)/**/*.[tj]{s,sx}'
  21. - '**/tsconfig*.json'
  22. - '{package,now,vercel}.json'
  23. - '**/*.less'
  24. - 'docs-ui/**'
  25. - 'static/**'
  26. - 'fixtures/search-syntax/**/*'
  27. - '.github/workflows/frontend.yml'
  28. frontend_all: &frontend_all
  29. - *frontend_src
  30. - '**/*.[tj]{s,sx}'
  31. frontend_modified_lintable:
  32. - added|modified: *frontend_lintable
  33. frontend_components_modified_lintable:
  34. - added|modified: *frontend_components_lintable
  35. # Also used in `getsentry-dispatch.yml` to dispatch backend tests on getsentry
  36. backend_dependencies: &backend_dependencies
  37. - 'requirements-*.txt'
  38. backend_build_changes: &backend_build_changes
  39. # If you change this line make sure that workflows using this action (e.g. acceptance, api_docs)
  40. # *and* file-filters would be updated as well
  41. - '.github/actions/setup-sentry/action.yml'
  42. - '.github/workflows/backend.yml'
  43. - '.pre-commit-config.yaml'
  44. - 'Makefile'
  45. - 'pyproject.toml'
  46. # `backend_src` filters on files that are backend changes excluding
  47. # changes to the tests/ directory.
  48. # If you want to filter on *all* backend files, use the `backend_all` filter.
  49. backend_src: &backend_src
  50. - *backend_build_changes
  51. - *backend_dependencies
  52. - '!(tests)/**/*.py'
  53. - '**/*.sh'
  54. - '**/*.pysnap'
  55. - 'src/sentry/!(static)/**'
  56. - 'migrations_lockfile.txt'
  57. - 'config/**/*'
  58. - 'fixtures/search-syntax/**/*'
  59. backend_all: &backend_all
  60. - *backend_src
  61. - '**/*.py'
  62. # This is the ultimate controller for acceptance.yml
  63. acceptance: &acceptance
  64. - *backend_all
  65. - *frontend_all
  66. # This is verbose because backend_build_changes includes it, however,
  67. - '.github/actions/setup-sentry/action.yml'
  68. - '.github/workflows/acceptance.yml'
  69. plugins: &plugins
  70. - *backend_all
  71. - 'src/sentry_plugins/**/*.html'
  72. api_docs: &api_docs
  73. - *backend_all
  74. - 'api-docs/**'
  75. - 'tests/apidocs/**'
  76. # This is the ultimate controller for backend.yml
  77. backend_any_type: &backend_any_type
  78. - *backend_all
  79. - *api_docs
  80. - *plugins
  81. migrations_added:
  82. - added: 'src/sentry/migrations/*'
  83. migrations_modified:
  84. - modified: 'src/sentry/migrations/*'
  85. # These files will trigger our wokrflow to check if lockfile
  86. # updates are needed
  87. migration_lockfile:
  88. - *backend_dependencies
  89. - '**/*.py'
  90. - .github/workflows/check-if-migration-is-required.yml
  91. - .github/workflows/scripts/migration-check.sh