Skip to content

Commit

Permalink
Merge pull request #5 from ioanlucut/remove-line-separators-for-windows
Browse files Browse the repository at this point in the history
Remove line separators (Use LF)
  • Loading branch information
ioanlucut authored Jul 20, 2023
2 parents 82f3e52 + d5c24cc commit 2cc60d5
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 9 deletions.
12 changes: 12 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
trim_trailing_whitespace = true
insert_final_newline = true

[{*.js,*.ts(x)}]
insert_final_newline = true
2 changes: 1 addition & 1 deletion .env.remote
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
SOURCE_DIR=../bes-lyrics/verified
OUT_DIR=/Users/ilucut/WORK/BES/CLOUD DATA/ProPresenter_Generated/ProPresenter_Generated_Version_8
OUT_DIR=/Users/ilucut/WORK/BES/CLOUD DATA/ProPresenter_Generated/ProPresenter_Generated_Version_9
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.txt eol=lf diff=astextplain
10 changes: 3 additions & 7 deletions src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,15 @@ export const TXT_EXTENSION = '.txt';
export const TEST_FILE = 'TEMPLATE.txt';

export const ALLOWED_CHARS =
` {}&#!(),-./1234567890:;?ABCDEFGHIJKLMNOPRSTUVWXZYQ[\\]abcdefghijklmnopqrstuvwxyzÎâîăÂȘșĂȚț’”„\n\r`.split(
` {}&#!(),-./1234567890:;?ABCDEFGHIJKLMNOPRSTUVWXZYQ[\\]abcdefghijklmnopqrstuvwxyzÎâîăÂȘșĂȚț’”„\n`.split(
EMPTY_STRING,
);

export const NEW_LINE = '\n';

export const CARRIAGE_RETURN = '\r';

export const NEW_LINE_TUPLE = `${CARRIAGE_RETURN}${NEW_LINE}`;
export const NEW_LINE_TUPLE = '\n';

export const DOUBLE_LINE_TUPLE = `${NEW_LINE_TUPLE}${NEW_LINE_TUPLE}`;

export const CHARS_SEPARATORS = /[ !(),./:;?\r]+/;
export const CHARS_SEPARATORS = /[ !(),./:;?\n]+/;

export const ALT_SONGS_FILE_SUFFIX = /(- i|- ii)/;

Expand Down
1 change: 0 additions & 1 deletion src/songsParser.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ describe('songsParser', () => {
parseSong(
createAdvancedSongMock([
['v1', ['Subsection 1.1', 'Subsection 1.2'].join(DOUBLE_LINE_TUPLE)],

['v2', 'Section 2'],
['v3', 'Section 3'],
]),
Expand Down

0 comments on commit 2cc60d5

Please sign in to comment.