Page MenuHomePhabricator

Migrate operations-dns-tabs to a Docker container
Closed, ResolvedPublic

Description

operations/dns triggers operations-dns-tabs which does a very basic check for tabulations:

#!/bin/bash -e
echo "Looking for tabulations in files matching: *"
set -x
(grep --recursive -P '^\t' --exclude-dir='.git' --include='*' .) && HAS_TAB=1 || HAS_TAB=0
exit $HAS_TAB

Can probably be replaced with a git grep -P.
The job uses a shallow clone.

Event Timeline

greg triaged this task as Medium priority.Nov 29 2018, 4:42 AM

This can be done the sameway I have done for the typos job (T210284) by using git grep as the entry point ( https://gerrit.wikimedia.org/r/#/c/integration/config/+/475475/4/dockerfiles/typos/Dockerfile.template ):

FROM {{ "ci-src-setup-simple" | image_tag }} AS ci-src-setup

FROM {{ "ci-stretch" | image_tag }}
COPY --from=ci-src-setup /run.sh /ci-src-setup.sh

USER nobody
WORKDIR /src
ENTRYPOINT /ci-src-setup.sh && /usr/bin/git grep -E -I -f typos -- . ':(exclude)typos'

Change 478930 had a related patch set uploaded (by Hashar; owner: Hashar):
[integration/config@master] docker: git grep to find leading tabulations

https://gerrit.wikimedia.org/r/478930

Change 478930 merged by jenkins-bot:
[integration/config@master] docker: git grep to find leading tabulations

https://gerrit.wikimedia.org/r/478930

Change 478935 had a related patch set uploaded (by Hashar; owner: Hashar):
[integration/config@master] tabs job on Docker

https://gerrit.wikimedia.org/r/478935

Change 478935 merged by jenkins-bot:
[integration/config@master] tabs job on Docker

https://gerrit.wikimedia.org/r/478935

hashar claimed this task.