pino added a comment.
In D19812#436174 <https://phabricator.kde.org/D19812#436174>, @guoyunhe wrote: > In D19812#436154 <https://phabricator.kde.org/D19812#436154>, @pino wrote: > > > - please harden the script using at least -e and -u flags for set: this way, it will not keep executing when a command fails, and undeclared variables are not silently expanded to empty string (to prevent typos) > > > Sorry, I am not very familiar with shell script. What does the -e or -u flags mean and how to use them? Can you give an example? Thanks. - -e: exits whenever any of the programs return a non-zero (i.e. failure) return code; this is useful to not silently ignore failures, and makes the behaviour similar to each line in a target of a Makefile - -u: immediately fails when trying to expand a variable that was not previously set; this way, things like `mkdir "$DIR/foo"` will immediately fail if `$FOO` was not set previously (so prevent misbehaviours due to typos, or code path not taken into account) INLINE COMMENTS > generate_web_data.sh:7 > +then > + echo "Error: Directory $DIR/icons does not exist." > + exit this should go to stderr, as it is an error > generate_web_data.sh:13 > +then > + echo "Error: Directory $DIR/icons-dark does not exist." > + exit ditto > index.html:93 > + > + <script src="https://unpkg.com/vue"></script> > + Always using the network is not exactly a good idea: - the page is unusable if there is no Internet connection - this (private!) website will be phoned home every time an user loads this page locally, without even notifying the user At least in Debian I see a `libjs-vue` package, so please make sure to work with local copies only. Otherwise this is a big privacy concern. REPOSITORY R266 Breeze Icons REVISION DETAIL https://phabricator.kde.org/D19812 To: guoyunhe, ngraham, #vdg, ndavis, #breeze Cc: pino, bcooksley, ngraham, kde-frameworks-devel, michaelh, bruns