@gkalpak/aliases 0.10.6 → 0.10.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/config/cfgbash.js +1 -1
- package/bin/config/cfgbash.wsl.js +1 -1
- package/bin/config/cfggit.js +1 -1
- package/bin/config/cfggit.win32.js +1 -1
- package/bin/config/cfggit.wsl.js +1 -1
- package/bin/config/cfggpg.js +1 -1
- package/bin/config/cfgssh.js +1 -1
- package/bin/config/cfgvim.js +1 -1
- package/bin/config/cfgwsl.js +11 -0
- package/bin/config/cfgwsl.wsl.js +22 -0
- package/bin/misc/alv.js +1 -1
- package/lib/constants.js +32 -0
- package/package.json +2 -1
package/bin/config/cfgbash.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
/* eslint-disable max-len */
|
|
4
4
|
console.log(stripIndentation(`
|
|
5
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
5
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
6
6
|
### Copy the following into '~/.bashrc':
|
|
7
7
|
|
|
8
8
|
# Set up prompt.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
/* eslint-disable max-len */
|
|
4
4
|
console.log(stripIndentation(`
|
|
5
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
5
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
6
6
|
### Copy the following into '~/.bashrc':
|
|
7
7
|
|
|
8
8
|
# Set up prompt.
|
package/bin/config/cfggit.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
console.log(stripIndentation(`
|
|
4
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
5
|
### Run the following commands:
|
|
6
6
|
|
|
7
7
|
git config --global commit.gpgSign true
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
console.log(stripIndentation(`
|
|
4
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
5
|
### Run the following commands:
|
|
6
6
|
|
|
7
7
|
git config --global commit.gpgSign true
|
package/bin/config/cfggit.wsl.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
console.log(stripIndentation(`
|
|
4
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
5
|
### Run the following commands:
|
|
6
6
|
|
|
7
7
|
git config --global commit.gpgSign true
|
package/bin/config/cfggpg.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
console.log(stripIndentation(`
|
|
4
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
5
|
### Copy the following into '~/.gnupg/gpg-agent.conf':
|
|
6
6
|
|
|
7
7
|
default-cache-ttl 86400
|
package/bin/config/cfgssh.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {stripIndentation} from '../../lib/utils.js';
|
|
3
3
|
console.log(stripIndentation(`
|
|
4
|
-
### [Generated by: @gkalpak/aliases v0.10.
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
5
|
### Copy the following into '~/.ssh/config':
|
|
6
6
|
|
|
7
7
|
IdentityFile ~/.ssh/id-rsa-gkalpak.ppk
|
package/bin/config/cfgvim.js
CHANGED
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
import {readFileSync} from 'node:fs';
|
|
3
3
|
import {fileURLToPath} from 'node:url';
|
|
4
4
|
const __dirname = fileURLToPath(new URL('.', import.meta.url));
|
|
5
|
-
console.log('""" [Generated by: @gkalpak/aliases v0.10.
|
|
5
|
+
console.log('""" [Generated by: @gkalpak/aliases v0.10.7]');
|
|
6
6
|
console.log('""" Copy the following into \'~/.vimrc\':\n');
|
|
7
7
|
console.log(readFileSync(`${__dirname}/../../lib/assets/vimrc.txt`, 'utf8').trim() + '\n');
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {commandUtils} from '@gkalpak/cli-utils';
|
|
3
|
+
import {isMain, onError} from '../../lib/utils.js';
|
|
4
|
+
// eslint-disable-next-line max-len
|
|
5
|
+
const cmd = 'node --print "\'This alias only works in WSL.\'"';
|
|
6
|
+
export default cmd;
|
|
7
|
+
if (isMain(import.meta.url)) {
|
|
8
|
+
const {args, config} = commandUtils.preprocessArgs(process.argv.slice(2));
|
|
9
|
+
// eslint-disable-next-line quotes
|
|
10
|
+
commandUtils.run(cmd, args, Object.assign({"sapVersion":2}, config)).catch(onError);
|
|
11
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {stripIndentation} from '../../lib/utils.js';
|
|
3
|
+
console.log(stripIndentation(`
|
|
4
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
5
|
+
### Copy the following into a root-owned, 600-mode '/etc/resolv.conf' file:
|
|
6
|
+
|
|
7
|
+
# Cloudflare
|
|
8
|
+
nameserver 1.1.1.1
|
|
9
|
+
nameserver 1.0.0.1
|
|
10
|
+
|
|
11
|
+
# Google
|
|
12
|
+
nameserver 8.8.8.8
|
|
13
|
+
nameserver 8.8.4.4
|
|
14
|
+
|
|
15
|
+
-----
|
|
16
|
+
|
|
17
|
+
### [Generated by: @gkalpak/aliases v0.10.7]
|
|
18
|
+
### Copy the following into a root-owned, 600-mode '/etc/wsl.conf' file:
|
|
19
|
+
|
|
20
|
+
[network]
|
|
21
|
+
generateResolvConf = false
|
|
22
|
+
`));
|
package/bin/misc/alv.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
console.log('@gkalpak/aliases v0.10.
|
|
2
|
+
console.log('@gkalpak/aliases v0.10.7');
|
package/lib/constants.js
CHANGED
|
@@ -546,6 +546,38 @@ const ALIASES = {
|
|
|
546
546
|
console.log(readFileSync(\`\${__dirname}/../../lib/assets/vimrc.txt\`, 'utf8').trim() + '\\n');
|
|
547
547
|
`),
|
|
548
548
|
'Show configuration instructions for `vim`.')),
|
|
549
|
+
|
|
550
|
+
|
|
551
|
+
// WSL
|
|
552
|
+
cfgwsl: new Alias({
|
|
553
|
+
default: new AliasSpecDefault('node --print "\'This alias only works in WSL.\'"'),
|
|
554
|
+
wsl: new AliasSpec(
|
|
555
|
+
stripIndentation(`
|
|
556
|
+
#!/usr/bin/env node
|
|
557
|
+
import {stripIndentation} from '../../lib/utils.js';
|
|
558
|
+
console.log(stripIndentation(\`
|
|
559
|
+
### [Generated by: ${VERSION_STAMP}]
|
|
560
|
+
### Copy the following into a root-owned, 600-mode '/etc/resolv.conf' file:
|
|
561
|
+
|
|
562
|
+
# Cloudflare
|
|
563
|
+
nameserver 1.1.1.1
|
|
564
|
+
nameserver 1.0.0.1
|
|
565
|
+
|
|
566
|
+
# Google
|
|
567
|
+
nameserver 8.8.8.8
|
|
568
|
+
nameserver 8.8.4.4
|
|
569
|
+
|
|
570
|
+
-----
|
|
571
|
+
|
|
572
|
+
### [Generated by: ${VERSION_STAMP}]
|
|
573
|
+
### Copy the following into a root-owned, 600-mode '/etc/wsl.conf' file:
|
|
574
|
+
|
|
575
|
+
[network]
|
|
576
|
+
generateResolvConf = false
|
|
577
|
+
\`));
|
|
578
|
+
`),
|
|
579
|
+
'Show configuration instructions for setting up WSL.'),
|
|
580
|
+
}),
|
|
549
581
|
},
|
|
550
582
|
|
|
551
583
|
// Misc
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gkalpak/aliases",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.7",
|
|
4
4
|
"description": "My global aliases.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Utility"
|
|
@@ -45,6 +45,7 @@
|
|
|
45
45
|
"cfggpg": "./bin/config/cfggpg.js",
|
|
46
46
|
"cfgssh": "./bin/config/cfgssh.js",
|
|
47
47
|
"cfgvim": "./bin/config/cfgvim.js",
|
|
48
|
+
"cfgwsl": "./bin/config/cfgwsl.js",
|
|
48
49
|
"dkrall": "./bin/docker/dkrall.js",
|
|
49
50
|
"dkratt": "./bin/docker/dkratt.js",
|
|
50
51
|
"dkrbd": "./bin/docker/dkrbd.js",
|