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

convert-spaces-to-tabs does not work #79

Closed
chrisgrieser opened this issue Sep 25, 2021 · 5 comments · Fixed by #96
Closed

convert-spaces-to-tabs does not work #79

chrisgrieser opened this issue Sep 25, 2021 · 5 comments · Fixed by #96

Comments

@chrisgrieser
Copy link
Contributor

Testing exactly the rule from rules.ts at sites like regex101 or via a simple templater script, it does work as intended. When running tests with rules.ts, it also works.

But it does not seem to work in the linter. I assume it should therefore be sth related to the linter? :(

@platers
Copy link
Owner

platers commented Sep 25, 2021

Is your tabsize 4? I think its because its treating anything indented with 4 spaces to be a code block, and ignoring it. I guess this rule shouldnt ignore codeblocks

@chrisgrieser
Copy link
Contributor Author

Was my first guess as well, but it also did not work when settings tabsize to 3 or 2

@platers
Copy link
Owner

platers commented Sep 25, 2021

hmm, it works for me. What text is it failing on for you?

@chrisgrieser
Copy link
Contributor Author

I have simply used Lorem Ipsum text:

- Lorem ipsum dolor sit amet, consectetur adipiscing elit. 
    - Vestibulum id tortor lobortis, tristique mi quis, pretium metus. 
- Nunc ut arcu fermentum enim auctor accumsan ut a risus. 
        - Donec ut auctor dui. 

here, the spaces are not converted to tabs, even though Obsidian does not recognize them as codeblocks or yaml.

Testing the Regex here works fine, though: https://regex101.com/r/pDwcA0/1/

@platers
Copy link
Owner

platers commented Sep 25, 2021

I see, this is the same bug as #75, linter thinks those lines are indented code blocks when theyre not.
This should get fixed when I get around to #76

@platers platers linked a pull request Oct 8, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants