Skip to content

Add script and documentation for minimizing patches #3462

Closed
@code-asher

Description

@code-asher

We can see the differences between code-server and VS Code with something like this (will have to be tweaked to work in all cases):

#!/usr/bin/env bash
set -euo pipefail

main() {
  cd "$(dirname "$0")/../.."

  local upstream=$1 ; shift
  local main=$1 ; shift

  git diff "$upstream" "$main" --name-only \
    | grep -v 'yarn.lock$' \
    | grep -v '^src/typings/' \
    | xargs git diff "$upstream" "$main" --
}

main "$@"

Example usage:

./diff.bash vscode/release/1.57 origin/main:lib/vscode

So I'm thinking we should make this part of the upgrade process to ensure we don't have differences we shouldn't (currently we do, probably somehow happened in the various squashes) and to help us keep tabs on what we've actually changed. There are changes we've made here that we can move out or refactor to minimize future conflicts.

Metadata

Metadata

Assignees

Labels

choreRelated to maintenance or clean up

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions