Skip to content

Add --reuse-hashes option to update script#50

Merged
chriseth merged 2 commits intogh-pagesfrom
update-script-reuse-hashes
Jul 28, 2020
Merged

Add --reuse-hashes option to update script#50
chriseth merged 2 commits intogh-pagesfrom
update-script-reuse-hashes

Conversation

@cameel
Copy link
Copy Markdown
Collaborator

@cameel cameel commented Jul 28, 2020

Part of argotorg/solidity#9258. The PR is based on #49 but only for convenience - both modify processDir() function and would conflict otherwise.

You can now run ./update --reuse-hashes and have the script finish almost immediately if list.json files already exist.

Note that the update script usually truncates the lists just after it starts and only then all the heavy processing happens. That's probably due to lazy evaluation of parsedList. This means that if you interrupt it or if it fails for some reason, you should revert the lists using git or it will have to recalculate all hashes anyway.

@cameel cameel requested a review from chriseth July 28, 2020 12:01
@cameel cameel self-assigned this Jul 28, 2020
@chriseth chriseth force-pushed the make-update-script-create-wasm-symlinks branch from c487c04 to a6aff48 Compare July 28, 2020 13:16
cameel added 2 commits July 28, 2020 15:18
…sier

- generateLegacyListJS() moved to the top not to obscure the part of the script that's outside of any functions.
- readFile() and buildVersion() Moved out of processDir() because makeEntry() uses them.
- The code for generating entries on the list extracted into makeEntry(). I'm going to make it longer and keeping it inside a map() call hurts readability.
@chriseth chriseth force-pushed the update-script-reuse-hashes branch from c22e150 to 68b1834 Compare July 28, 2020 13:18
@chriseth chriseth changed the base branch from make-update-script-create-wasm-symlinks to gh-pages July 28, 2020 13:18
@chriseth
Copy link
Copy Markdown
Contributor

Rebased.

@chriseth chriseth merged commit ce22f02 into gh-pages Jul 28, 2020
@cameel cameel deleted the update-script-reuse-hashes branch July 28, 2020 14:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants