Skip to content

Commit c68f540

Browse files
authored
Add EOL to a bunch of files (hestiacp#4530)
* prettier complain if not end with newline * a bunch of newlines. the newlines were created with the following script: <?php declare(strict_types=1); $dir = realpath(__DIR__ . '/..'); chdir($dir); foreach ((new RecursiveIteratorIterator(new RecursiveDirectoryIterator($dir, RecursiveDirectoryIterator::SKIP_DOTS))) as $file) { if ($file->isDir()) { continue; } if ($file->isLink()) { continue; } $size = $file->getSize(); if ($size === 0) { continue; } $path = $file->getPathname(); $blacklist = array( '/.git/', '/node_modules/', '/vendor/', 'rex:/\\.svg$/i' ); foreach ($blacklist as $pattern) { $isBlacklisted = str_starts_with($pattern, 'rex:') ? preg_match(substr($pattern, strlen('rex:')), $path) : str_contains($path, $pattern); if ($isBlacklisted) { continue 2; } } $content = file_get_contents($path); // is binary? if(strlen($content) !== strcspn($content, "\x00\x01\x02\x03\x04\x05\x06\x07\x08")) { //var_dump("skipping binary file: {$path}"); continue; } $lastByte = substr($content, -1); if ($lastByte === "\n") { continue; } var_dump($path, $lastByte); $content .= "\n"; file_put_contents($path, $content, LOCK_EX); } ?> * prettier fix
1 parent 9ce0b51 commit c68f540

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+42
-40
lines changed

.prettierrc.cjs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ module.exports = {
99
// PHP Settings
1010
phpVersion: '8.2',
1111
braceStyle: '1tbs',
12+
endOfLine: 'lf',
13+
1214
// Overrides for some files
1315
overrides: [
1416
// JavaScript files

install/common/dovecot/sieve/20-managesieve.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,4 +85,4 @@ protocol sieve {
8585
#log_path = /var/log/dovecot-sieve-errors.log
8686
#info_log_path = /var/log/dovecot-sieve.log
8787

88-
}
88+
}

install/common/dovecot/sieve/90-sieve-extprograms.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,4 @@ plugin {
4141
# user = vmail
4242
# mode = 0600
4343
#}
44-
#}
44+
#}

install/common/templates/dns/office365.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@ ID='18' RECORD='enterpriseenrollment' TYPE='CNAME' PRIORITY='' VALUE='enterprise
1919
ID='19' RECORD='_sip._tls' TYPE='SRV' PRIORITY='100' VALUE='1 443 sipdir.online.lync.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
2020
ID='20' RECORD='_sipfederationtls._tcp' TYPE='SRV' PRIORITY='100' VALUE='1 5061 sipfed.online.lync.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
2121
ID='21' RECORD='login' TYPE='CNAME' PRIORITY='' VALUE='login.microsoftonline.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
22-
ID='22' RECORD='mail' TYPE='CNAME' PRIORITY='' VALUE='mail.office365.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
22+
ID='22' RECORD='mail' TYPE='CNAME' PRIORITY='' VALUE='mail.office365.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'

install/common/templates/dns/zoho.tpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@ ID='11' RECORD='www' TYPE='CNAME' PRIORITY='' VALUE='%domain%.' SUSPENDED='no' T
1212
ID='12' RECORD='@' TYPE='MX' PRIORITY='10' VALUE='mx.zoho.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
1313
ID='13' RECORD='@' TYPE='MX' PRIORITY='20' VALUE='mx2.zoho.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
1414
ID='14' RECORD='@' TYPE='MX' PRIORITY='50' VALUE='mx3.zoho.com.' SUSPENDED='no' TIME='%time%' DATE='%date%'
15-
ID='15' RECORD='@' TYPE='TXT' PRIORITY='' VALUE='"v=spf1 a mx ip4:%ip% include:zoho.com -all"' SUSPENDED='no' TIME='%time%' DATE='%date%'
15+
ID='15' RECORD='@' TYPE='TXT' PRIORITY='' VALUE='"v=spf1 a mx ip4:%ip% include:zoho.com -all"' SUSPENDED='no' TIME='%time%' DATE='%date%'

install/deb/apache2/hestia-event.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
<FilesMatch \.php$>
33
SetHandler "proxy:fcgi://127.0.0.1:9000"
44
</FilesMatch>
5-
</IfModule>
5+
</IfModule>

install/deb/bind/named.conf.options

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ options {
2121
hostname none;
2222
server-id none;
2323
version none;
24-
};
24+
};

install/deb/exim/limit.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
200
1+
200

install/deb/exim/system.filter

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ then
1313
headers remove "Subject"
1414
headers add "Subject: *** VIRUS *** $h_old-subject"
1515
headers remove "Old-Subject"
16-
endif
16+
endif

install/deb/fail2ban/action.d/hestia.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ actionstart = /usr/local/hestia/bin/v-add-firewall-chain <name>
66
actionstop = /usr/local/hestia/bin/v-delete-firewall-chain <name>
77
actioncheck = iptables -n -L INPUT | grep -q 'fail2ban-<name>[ \t]'
88
actionban = /usr/local/hestia/bin/v-add-firewall-ban <ip> <name>
9-
actionunban = /usr/local/hestia/bin/v-delete-firewall-ban <ip> <name>
9+
actionunban = /usr/local/hestia/bin/v-delete-firewall-ban <ip> <name>

0 commit comments

Comments
 (0)