You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm finally polishing up the config diffing code I wrote in December, which would simplify comparing one generated CI config with another. The CLI UX for this is a bit tricky, though. There's a number of comparisons that make sense:
Comparing a config file against the default config
Comparing a Travis/GitHub/bash file against the default config
Comparing 2 config files
Comparing 2 CI files against each other
Comparing a CI file against a config file
The "obvious" UX is diff with 1 argument compares against the default config and with 2 arguments it diffs those two files. There are two tricky UX parts:
What would it mean if there are commandline options passed to the diff command
How do we know if a file is a config file?
The first issue can be trivially solved by refactoring some of the optparse code in HaskellCI.Cli to move the flags/options into the subcommands and simply disallowing commandline options to a diff subcommand. Becomes somewhat more challenging with the future goal of eliminating subcommands.
The second issue is trickier. CI files are easy to detect since they always use REGENDATA, which already has extraction code. But how to detect whether something is a config file? Do we simply assume a lack of REGENDATA means something is a haskell-ci config file?
The text was updated successfully, but these errors were encountered:
I'm finally polishing up the config diffing code I wrote in December, which would simplify comparing one generated CI config with another. The CLI UX for this is a bit tricky, though. There's a number of comparisons that make sense:
The "obvious" UX is
diff
with 1 argument compares against the default config and with 2 arguments it diffs those two files. There are two tricky UX parts:The first issue can be trivially solved by refactoring some of the optparse code in
HaskellCI.Cli
to move the flags/options into the subcommands and simply disallowing commandline options to a diff subcommand. Becomes somewhat more challenging with the future goal of eliminating subcommands.The second issue is trickier. CI files are easy to detect since they always use
REGENDATA
, which already has extraction code. But how to detect whether something is a config file? Do we simply assume a lack ofREGENDATA
means something is a haskell-ci config file?The text was updated successfully, but these errors were encountered: