Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Releases from master branch #869

Closed
IllusionMH opened this issue May 26, 2019 · 1 comment · Fixed by #878
Closed

Releases from master branch #869

IllusionMH opened this issue May 26, 2019 · 1 comment · Fixed by #878
Labels
Domain: Releases Scheduling and infrastructure around package releases. Domain: Tooling Repository tasks around improving source tooling. Status: In Discussion Please continue discussing the proposed change before sending a pull request.

Comments

@IllusionMH
Copy link
Contributor

Feature request

Is your feature request that we implement a new rule?
No

Is your feature request related to a problem? Please describe.
Current release process that requires to keep second repo copy for release branch and to manually copy files from dist/build to root of release branch is annoying and error prone (there is diff between folders already).

Currently there are differences in contents of dist/build and release branch:

$ diff -rwq ./dist/build/ ../tslint-microsoft-contrib-releases/
Only in /c/web/test/tslint-microsoft-contrib-releases/: .git
Only in /c/web/test/tslint-microsoft-contrib-releases/: recommended_ruleset.js
Only in /c/web/test/tslint-microsoft-contrib-releases/: tslint.json
Only in /c/web/test/tslint-microsoft-contrib-releases/utils: NoStringParameterToFunctionCallWalker.js
Only in /c/web/test/tslint-microsoft-contrib-releases/utils: ScopedSymbolTrackingWalker.js

Worth to note that tslint.json is absent in dist/build but will be used when users add "extends": ["tslint-microsoft-contrib"] to their tslint.json as shown in docs.

Also it has diff with legacy.json that we expect it should alias:

// tslint.json
- "no-function-constructor-with-string-args": true,
- "no-increment-decrement": true,
- "no-reserved-keywords": true,
- "no-unnecessary-bind": true,
// legacy.json
+ "no-function-constructor-with-string-args": false,
+ "no-increment-decrement": false,
+ "no-reserved-keywords": false,
+ "no-unnecessary-bind": false,
+ "function-constructor": true,
+ "increment-decrement": true,
+ "unnecessary-bind": true,
+ "void-zero": true,
+ "react-a11y-accessible-headings": true,

Basically legacy.json replaced deprecated rules with new from core, disabled no-reserved-keywords and has 2 new rules.

Describe the solution you'd like
Release packages directly from dist/build folder, this will enable #863. Also semantic-release supports releasing from specified directory (see pkgRoot)

If I understand correctly - removing files from package can be considered as breaking change and should be major version increment. To avoid this I propose to create folder with these files and copy them to dist/build during package build. This step will be removed in next major version.

As for tslint.json - two options possible:

  1. Leave as is and copy with other "missing" files (users will see deprecation warning)
  2. Remove changes for void-zero, react-a11y-accessible-headings from legacy.json and copy legacy.json as tslint.json to build/dist (OK if they have proper TSLint version, notification if they have old TSLint version).

Describe alternatives you've considered
#825 will be a breaking change due to changes in package structure while this change to build steps may be preliminary step.
Alternatively - #825 may be closed in favor of this

Additional context
N/A

@IllusionMH IllusionMH added Domain: Releases Scheduling and infrastructure around package releases. Domain: Tooling Repository tasks around improving source tooling. Status: In Discussion Please continue discussing the proposed change before sending a pull request. labels May 26, 2019
@IllusionMH
Copy link
Contributor Author

After offline discussion we decided to store missing files and copy them to dist/build, exclude new rules from legacy.js but leave change that disables deprecated in favor of core rules.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Domain: Releases Scheduling and infrastructure around package releases. Domain: Tooling Repository tasks around improving source tooling. Status: In Discussion Please continue discussing the proposed change before sending a pull request.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant