Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

alejandra vs editorconfig #294

Closed
blaggacao opened this issue May 31, 2022 · 1 comment · Fixed by #324
Closed

alejandra vs editorconfig #294

blaggacao opened this issue May 31, 2022 · 1 comment · Fixed by #324
Labels
component | style Modifications to the formatting rules good first issue Good for newcomers status | it is a good thing We agree it is good to implement this type | feature request New feature or request

Comments

@blaggacao
Copy link
Contributor

blaggacao commented May 31, 2022

the two flip-flop:

std on  main [$]alejandra --version
Alejandra 1.4.0

std on  main [$]editorconfig-checker

std on  main [$]alejandra . -q && editorconfig-checker
flake.nix:
	12: Wrong amount of left-padding spaces(want multiple of 2)
src/clades/data.nix:
	4: Wrong amount of left-padding spaces(want multiple of 2)
	5: Trailing whitespace
	5: Wrong amount of left-padding spaces(want multiple of 2)
	6: Wrong amount of left-padding spaces(want multiple of 2)
	7: Wrong amount of left-padding spaces(want multiple of 2)
	8: Wrong amount of left-padding spaces(want multiple of 2)
	9: Trailing whitespace
	9: Wrong amount of left-padding spaces(want multiple of 2)
	10: Wrong amount of left-padding spaces(want multiple of 2)
	11: Wrong amount of left-padding spaces(want multiple of 2)
	12: Wrong amount of left-padding spaces(want multiple of 2)
[ ... ]
384 errors found
@blaggacao
Copy link
Contributor Author

blaggacao commented May 31, 2022

A representative diff would be:

diff --git a/src/clades/data.nix b/src/clades/data.nix
index a285784..0d588b2 100644
--- a/src/clades/data.nix
+++ b/src/clades/data.nix
@@ -1,16 +1,16 @@
 {nixpkgs}: let
   l = nixpkgs.lib // builtins;
   /*
-  Use the Data Clade for json serializable data.
-
-  Available actions:
-    - write
-    - explore
-
-  For all actions is true:
-    Nix-proper 'stringContext'-carried dependency will be realized
-    to the store, if present.
-  */
+   Use the Data Clade for json serializable data.
+   
+   Available actions:
+     - write
+     - explore
+   
+   For all actions is true:
+     Nix-proper 'stringContext'-carried dependency will be realized
+     to the store, if present.
+   */
   data = name: {
     inherit name;
     clade = "data";

The problematic choices seem to be just:

  • Indent multiline comments by one
  • backfill with spaces to the left en empty lines

@kamadorueda kamadorueda added type | feature request New feature or request good first issue Good for newcomers component | style Modifications to the formatting rules status | it is a good thing We agree it is good to implement this labels Jun 13, 2022
blaggacao added a commit to blaggacao/alejandra that referenced this issue Jul 13, 2022
blaggacao added a commit to blaggacao/alejandra that referenced this issue Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component | style Modifications to the formatting rules good first issue Good for newcomers status | it is a good thing We agree it is good to implement this type | feature request New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants