Skip to content
Snippets Groups Projects
Select Git revision
  • test-lfs-concept
  • master default
  • rtde
  • tmp-gpg-key-workaround-2
  • tmp-gpg-key-workaround
  • 68-git-lfs-error-in-ddeploy-job
  • split-build-and-test
  • 66-jazzy-support
  • 62-deploy-jobs-do-not-pull-files-from-lfs-manual-lfs-pull
  • 62-deploy-jobs-do-not-pull-files-from-lfs-custom-docker-image
  • py3-without-industrial-ci-test
  • 58-add-yolo-pip-package-support
  • 55-collision-between-test-jobs-due-to-dds-autodiscovery-ros2
  • 52-ddeploy-job-failing-when-enforcing-labels-alt-quick-dind-test
  • 48-python3_syntax
  • 46-default-docker-image-name-too-long
  • 45-double-pipeline-triggered-if-merge-request-has-melodic-branch-name
  • 40-repo-is-ros-testing
  • test-badges
  • add-packages
20 results

Dockerfile

Blame
  • common.ts 6.26 KiB
    import { lexer, parser, query as q } from 'good-enough-parser';
    import { clone } from '../../../../util/clone';
    import { regEx } from '../../../../util/regex';
    import type { Ctx, NonEmptyArray, PackageVariables } from '../types';
    
    export const REGISTRY_URLS = {
      google: 'https://dl.google.com/android/maven2/',
      gradlePluginPortal: 'https://plugins.gradle.org/m2/',
      jcenter: 'https://jcenter.bintray.com/',
      mavenCentral: 'https://repo.maven.apache.org/maven2',
    };
    
    export const GRADLE_PLUGINS = {
      checkstyle: 'com.puppycrawl.tools:checkstyle',
      codenarc: 'org.codenarc:CodeNarc',
      detekt: 'io.gitlab.arturbosch.detekt:detekt-core',
      findbugs: 'com.google.code.findbugs:findbugs',
      googleJavaFormat: 'com.google.googlejavaformat:google-java-format',
      jacoco: 'org.jacoco:jacoco',
      lombok: 'org.projectlombok:lombok',
      pmd: 'net.sourceforge.pmd:pmd-java',
      spotbugs: 'com.github.spotbugs:spotbugs',
    };
    
    export const ANNOYING_METHODS: ReadonlySet<string> = new Set([
      'createXmlValueRemover',
      'events',
      'args',
      'arrayOf',
      'listOf',
      'mutableListOf',
      'setOf',
      'mutableSetOf',
      'stages', // https://github.com/ajoberstar/reckon,
      'mapScalar', // https://github.com/apollographql/apollo-kotlin
    ]);
    
    export function storeVarToken(ctx: Ctx, node: lexer.Token): Ctx {
      ctx.varTokens.push(node);
      return ctx;
    }
    
    export function increaseNestingDepth(ctx: Ctx): Ctx {
      ctx.tmpNestingDepth.push(...ctx.varTokens);
      ctx.varTokens = [];
      return ctx;
    }
    
    export function reduceNestingDepth(ctx: Ctx): Ctx {
      ctx.tmpNestingDepth.pop();
      return ctx;
    }
    
    export function prependNestingDepth(ctx: Ctx): Ctx {
      ctx.varTokens = [...clone(ctx.tmpNestingDepth), ...ctx.varTokens];
      return ctx;
    }
    
    export function storeInTokenMap(ctx: Ctx, tokenMapKey: string): Ctx {
      ctx.tokenMap[tokenMapKey] = ctx.varTokens;
      ctx.varTokens = [];
    
      return ctx;
    }
    
    export function loadFromTokenMap(
      ctx: Ctx,
      tokenMapKey: string
    ): NonEmptyArray<lexer.Token> {
      const tokens = ctx.tokenMap[tokenMapKey];