File tree Expand file tree Collapse file tree 2 files changed +0
-59
lines changed
scripts/compare-gas-usage Expand file tree Collapse file tree 2 files changed +0
-59
lines changed Original file line number Diff line number Diff line change @@ -153,33 +153,6 @@ perf-remove:
153153 echo " Removing canceled."
154154 fi
155155
156- # This recipe should be used on snapshot tests that contains gas usage from `forc test`,
157- # because it will extract gas usage from all versions of the file and generate an html interactive report.
158- # path: path to file to extract gas usage
159- # open: "-o" will open the default browser showing the report
160- [linux ]
161- [group (' benchmark' )]
162- collect-historic-gas-usage path open :
163- #! / bin/ bash
164- mkdir -p target
165- rm target/ a.csv
166- rm target/ a.html
167- echo " test,gas,commit" > target/ a.csv
168- for HASH in ` git log --format=' %H' -- {{path}} ` ; do
169- TIMESTAMP=$(git show -s --format=' %as-%ct-%H' " $HASH" )
170- git --no-pager show " $HASH:{{ path}} " | bash -c " scripts/compare-gas-usage/extract-gas-usage.sh $TIMESTAMP" >> target/ a.csv
171- done
172- ./ scripts/ csv2html/ csv2html.sh target/ a.csv >> target/ a.html
173- if [ -n " {{ open}} " ]; then
174- if which xdg-open &>> / dev/ null
175- then
176- xdg-open target/ a.html
177- elif which gnome-open &>> / dev/ null
178- then
179- gnome-open target/ a.html
180- fi
181- fi
182-
183156[group (' build' )]
184157build-prism :
185158 cd ./ scripts/ prism && ./ build.sh
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments