Skip to content

Commit d35837d

Browse files
committed
added some changes to allow for better memory use in UTs and added the changes for release prep
1 parent aca8509 commit d35837d

File tree

7 files changed

+15
-8
lines changed

7 files changed

+15
-8
lines changed

docs/docs/settings/spacing-rules.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -677,13 +677,13 @@ More content here
677677

678678
Alias: `heading-blank-lines`
679679

680-
All headings have a blank line both before and after (except where the heading is at the beginning or end of the document).
680+
All headings have one blank line both before and after (except where the heading is at the beginning or end of the document).
681681

682682
### Options
683683

684684
| Name | Description | List Items | Default Value |
685685
| ---- | ----------- | ---------- | ------------- |
686-
| `Bottom` | Insert a blank line after headings | N/A | `true` |
686+
| `Bottom` | Ensures one blank line after headings | N/A | `true` |
687687
| `Empty Line Between YAML and Header` | Keep the empty line between the YAML frontmatter and header | N/A | `true` |
688688

689689
### Additional Info

jest.config.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,7 @@ const config: Config.InitialOptions = {
1515
'!**/__integration__/*.[jt]s?(x)',
1616
'!**/test-vault/**/*.[jt]s?(x)',
1717
],
18+
// try to fix memory issues with jest when the UTs run
19+
workerIdleMemoryLimit: '200MB',
1820
};
1921
export default config;

manifest-beta.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"id": "obsidian-linter",
33
"name": "Linter",
4-
"version": "1.26.0-rc-3",
4+
"version": "1.26.0",
55
"minAppVersion": "1.5.7",
66
"description": "Formats and styles your notes. It can be used to format YAML tags, aliases, arrays, and metadata; footnotes; headings; spacing; math blocks; regular markdown contents like list, italics, and bold styles; and more with the use of custom rule options as well.",
77
"author": "Victor Tao",

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"id": "obsidian-linter",
33
"name": "Linter",
4-
"version": "1.25.0",
4+
"version": "1.26.0",
55
"minAppVersion": "1.5.7",
66
"description": "Formats and styles your notes. It can be used to format YAML tags, aliases, arrays, and metadata; footnotes; headings; spacing; math blocks; regular markdown contents like list, italics, and bold styles; and more with the use of custom rule options as well.",
77
"author": "Victor Tao",

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "obsidian-linter",
3-
"version": "1.26.0-rc-3",
3+
"version": "1.26.0",
44
"description": "Enforces consistent markdown styling for Obsidian (https://obsidian.md). It can be used to format YAML tags, aliases, arrays, and metadata; footnotes; headings; spacing; math blocks; regular markdown contents like list, italics, and bold styles; and more with the use of custom rule options as well.",
55
"main": "main.js",
66
"scripts": {

src/main.ts

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {createRunLinterRulesOptions, RulesRunner} from './rules-runner';
1111
import {LinterError} from './linter-error';
1212
import {LintConfirmationModal} from './ui/modals/lint-confirmation-modal';
1313
import {SettingTab} from './ui/settings';
14-
import {pasteUrlRegex} from './utils/regex';
14+
import {urlRegex} from './utils/regex';
1515
import {getTextInLanguage, LanguageStringKey, setLanguage} from './lang/helpers';
1616
import {RuleAliasSuggest} from './cm6/rule-alias-suggester';
1717
import {DEFAULT_SETTINGS, LinterSettings} from './settings-data';
@@ -618,10 +618,14 @@ export default class LinterPlugin extends Plugin {
618618
// because otherwise having 2 URLs cause Obsidian-breaking conflict.
619619
// Note: it looks like those two plugins look for an exact match for a URL,
620620
// so we will too.
621-
if (pasteUrlRegex.test(plainClipboard.trim())) {
621+
const text = plainClipboard.trim();
622+
if (urlRegex.test(text)) {
623+
// debugger;
624+
console.log('failed: "' + text + '"');
622625
logWarn(getTextInLanguage('logs.paste-link-warning'));
623626
return;
624627
}
628+
console.log('passed: "' + text + '"');
625629

626630
// prevent default pasting & abort when not successful
627631
clipboardEv.stopPropagation();

versions.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,5 +63,6 @@
6363
"1.23.1": "1.4.16",
6464
"1.23.2": "1.4.16",
6565
"1.24.0": "1.5.7",
66-
"1.25.0": "1.5.7"
66+
"1.25.0": "1.5.7",
67+
"1.26.0": "1.5.7"
6768
}

0 commit comments

Comments
 (0)