From ec4e732a3fab042aa784738915af05728f5b6f4e Mon Sep 17 00:00:00 2001
From: Adar Nimrod <nimrod@shore.co.il>
Date: Sun, 3 Oct 2021 23:54:51 +0300
Subject: [PATCH] Don't run pre-commit on scheduled builds.

There's really no point in it. I usually keep the master branch
buildable and working so running pre-commit is a waste of time and a
source for failed builds that shouldn't be.
---
 templates/pre-commit.yml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/templates/pre-commit.yml b/templates/pre-commit.yml
index 8bb1f7f..b669453 100644
--- a/templates/pre-commit.yml
+++ b/templates/pre-commit.yml
@@ -3,6 +3,8 @@ pre-commit:
   stage: .pre
   image: registry.shore.co.il/ci-images:pre-commit
   tags: [ns4.shore.co.il]
+  rules:
+    - if: $CI_PIPELINE_SOURCE != "schedule"
   variables:
     XDG_CACHE_HOME: "$CI_PROJECT_DIR/.cache"
     SKIP: |-
-- 
GitLab