Commit Graph

36 Commits (f21c6b6eacad4542a2c02606d43ba70814d7a919)

Author SHA1 Message Date
d-dorazio f21c6b6eac rework the cli interface 2017-10-03 23:32:36 +02:00
Lennart Spitzner bb40870f81 Merge pull request #59 from d-dorazio/master 2017-10-02 14:13:27 +02:00
d-dorazio 95c40f2b1e address review comments 2017-10-02 13:55:52 +02:00
d-dorazio 36af16f881 add inplace flag 2017-10-01 17:04:20 +02:00
d-dorazio 308da71afb support multiple inputs and outputs 2017-10-01 17:04:20 +02:00
Lennart Spitzner a348ae7fbc Switch to XDG path for config; Search conf in parents
- switch to XDG path should be backwards-compatible:
  - new config will be written to XDG path
  - but existing config in ~/.brittany will be respected
- looks for "brittany.yaml" not only in cwd, but in parents too.
  uses the first file found.

fixes #45, fixes #55
2017-09-29 21:42:39 +02:00
Lennart Spitzner 9703ebead5 Fix #53
Previously, if the input did not end with a newline
character and config had 'ppconf_hackAroundIncludes = True'
then due to using unlines/lines the output contained an
additional newline.
2017-09-10 16:37:35 +02:00
Lennart Spitzner b0f211fbfc Add/Use flag `-h` for `--help`, fixes #44 2017-08-10 17:46:21 +02:00
Lennart Spitzner 08e94f0e74 Differentiate ErrNos 2017-08-08 00:47:04 +02:00
Lennart Spitzner 69c50bebd3 Refactor Main.hs in preparation of --inplace (see #40) 2017-08-08 00:46:09 +02:00
Lennart Spitzner 16f5aa118d Add flag to omit reformatting (ghc-exactprint only) 2017-06-03 21:01:24 +02:00
Lennart Spitzner 8443988af3 Change help text 2017-06-03 18:23:03 +02:00
Lennart Spitzner 9f4cda9130 Add license (AGPLv3) 2017-06-03 18:23:03 +02:00
Lennart Spitzner dfec26e55b Refactor/Rename LayoutError -> BrittanyError 2017-06-03 18:23:03 +02:00
Lennart Spitzner f350113f7f Refactor all modules: +Internal; Add public Brittany module 2017-05-22 21:25:08 +02:00
Lennart Spitzner 5dbe0f2c9c Add function pureModuleTransform 2017-05-22 21:06:02 +02:00
Lennart Spitzner 72c87b7b4e Auto-reformat Main.hs 2017-05-22 15:58:04 +02:00
Lennart Spitzner fd9427754e Add "hackAroundIncludes" option (default false)
- Makes brittany work in stdin/stdout mode when
  CPP usage is limited to #includes.
2017-05-22 15:49:18 +02:00
Lennart Spitzner 8f1e366f9c Change config file structure; Add config version tag 2017-05-21 16:48:05 +02:00
Lennart Spitzner 296629b96c Update README.md (installation); Fix copyright notice 2017-05-17 23:31:20 +02:00
Lennart Spitzner 68e77c9337 Fixup for czipwith and Update stack.yaml 2017-05-14 19:32:31 +02:00
Lennart Spitzner 22300d9c62 Minor cleanups 2017-05-14 17:10:20 +02:00
Lennart Spitzner 2dd6fe83f5 Add documentation and examples; Add debugging flag; Minor refactors 2017-03-30 22:47:00 +02:00
Lennart Spitzner bc70eb07e8 Change config setup(!), Refactor, Update deps
- config now uses foo_bar instead of _foo_bar;
- config now will accept missing keys;
- use latest butcher version;
- improve identity testing by moving into separate file.
2017-01-31 18:43:16 +01:00
Lennart Spitzner 508780466c Adapt for butcher-0.2.0.0 2016-10-01 19:06:55 +02:00
Lennart Spitzner 65fee7694d Add commandline param for input (without --input) 2016-09-06 15:29:13 +02:00
Lennart Spitzner 94651934b4 Update --help output 2016-09-04 14:24:19 +02:00
Lennart Spitzner b03996e401 Apply brittany on parts of its source; Add comments 2016-09-03 23:02:32 +02:00
Lennart Spitzner b58a8b0146 Fix commandline flag parsing (again, oops) 2016-08-12 20:57:37 +02:00
Lennart Spitzner d444c6e386 Add check of syntactic validity of output 2016-08-12 15:01:15 +02:00
Lennart Spitzner 6011726389 Show yaml representation when dumping config 2016-08-08 17:59:29 +02:00
Lennart Spitzner 1a70e4d949 Support --ghc-options; Rework config internals 2016-08-08 17:59:29 +02:00
Lennart Spitzner d625c90461 Refactor Main/Brittany.hs, code structure 2016-08-08 17:34:17 +02:00
Lennart Spitzner 23f19e653f Improve config file handling (local+user conf files) 2016-08-07 15:14:57 +02:00
Lennart Spitzner e855b346b3 Change/Amend program/version description 2016-07-30 15:43:06 +02:00
Lennart Spitzner 60d1bc5176 Squash previous history 2016-07-30 15:22:07 +02:00