sourcegraph / src-cli

Sourcegraph CLI
https://sourcegraph.com
Apache License 2.0
275 stars 60 forks source link

code-search: fix fork attribute for src-cli batch changes #1045

Closed BolajiOlajide closed 11 months ago

BolajiOlajide commented 11 months ago

This upgrades the lib package in src-cli so that it contains the fixes for the fork attribute of non-server-side batch changes.

Test plan

Demo Tested on my local instance with several spec to be sure we cover all cases.

// Draft Changeset

name: testing-fork-specs-3
description: testing fork for changesets

on: 
  - repository: github.com/sourcegraph-testing/zap

steps:
  - run: IFS=$'\n'; echo "Testing" | tee -a $(find -name README.md)
    container: alpine:3

changesetTemplate:
  title: Hello World
  body: My first batch change!
  commit:
    message: Append Hello World to all README.md files
  branch: ${{ batch_change.name }}
  fork: true
  published: draft
// Published Changeset
name: testing-fork-specs-2
description: testing fork for changesets

on: 
  - repository: github.com/sourcegraph-testing/etcd

steps:
  - run: IFS=$'\n'; echo "Testing" | tee -a $(find -name README.md)
    container: alpine:3

changesetTemplate:
  title: Hello World
  body: My first batch change!
  commit:
    message: Append Hello World to all README.md files
  branch: ${{ batch_change.name }}
  fork: true
  published: true
// Unpublished Changeset
name: testing-fork-specs
description: testing fork for changesets

on: 
  - repository: github.com/sourcegraph-testing/markdowns

steps:
  - run: IFS=$'\n'; echo "Testing" | tee -a $(find -name README.md)
    container: alpine:3

changesetTemplate:
  title: Hello World
  body: My first batch change!
  commit:
    message: Append Hello World to all README.md files
  branch: ${{ batch_change.name }}
  fork: true