Skip to content

Commit 941c9ad

Browse files
authored
v2.0.0 (#262)
* v2.0.0
1 parent 050d946 commit 941c9ad

File tree

6 files changed

+36
-22
lines changed

6 files changed

+36
-22
lines changed

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,17 @@ All notable changes to this project will be documented in this file.
44

55
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [2.0.0] - 16-Jun-2024
8+
9+
### Changed
10+
11+
- Switch to ESM module
12+
- Bump eslint to version 9.5, with migrated config file
13+
- Drop eslint-config-airbnb-base and eslint-plugin-import
14+
- Other dev dependency bumps
15+
- MacOS Specific tweaks for testing
16+
- GitHub Action version bumps
17+
718
## [1.2.0] - 15-Oct-2023
819

920
### Changed
@@ -46,6 +57,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
4657

4758
### Initial Release
4859

60+
[2.0.0]: https://github.com/AndrewLane/ssh-keygen2/compare/v1.2.0...v2.0.0
4961
[1.2.0]: https://github.com/AndrewLane/ssh-keygen2/compare/v1.1.4...v1.2.0
5062
[1.1.4]: https://github.com/AndrewLane/ssh-keygen2/compare/v1.1.3...v1.1.4
5163
[1.1.3]: https://github.com/AndrewLane/ssh-keygen2/compare/v1.1.2...v1.1.3

README.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -29,16 +29,16 @@ command to be installed and in the path.
2929
### Usage
3030

3131
```js
32-
var keygen = require('@andrewwlane/ssh-keygen2')
33-
, assert = require('assert')
32+
import keygen from "@andrewwlane/ssh-keygen2";
33+
import assert from "assert";
3434

3535
// generate a temporary keypair and return details
3636
keygen(function (err, keypair) {
3737
assert.ifError(err);
3838
console.log(keypair.private);
3939
console.log(keypair.public);
40-
console.log(keypair.fingerprint + '\n');
41-
console.log(keypair.randomart + '\n');
40+
console.log(keypair.fingerprint + "\n");
41+
console.log(keypair.randomart + "\n");
4242
});
4343
```
4444

@@ -93,24 +93,24 @@ ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDRjv3GW0oAWhusF7+4jIOhkkax33jqOyIUE1dSnkun
9393
With full options:
9494

9595
```js
96-
var keygen = require('@andrewwlane/ssh-keygen2')
97-
, assert = require('assert')
96+
import keygen from "@andrewwlane/ssh-keygen2";
97+
import assert from "assert";
9898

9999
var opts = {
100-
type: 'rsa',
100+
type: "rsa",
101101
bits: 4096,
102-
passphrase: 'this will encrypt the private key',
103-
location: '/path/to/id_rsa',
102+
passphrase: "this will encrypt the private key",
103+
location: "/path/to/id_rsa",
104104
keep: true, // this will keep the resulting files
105-
comment: 'optional comment for ssh public key'
105+
comment: "optional comment for ssh public key",
106106
};
107107

108108
keygen(opts, function (err, keypair) {
109109
assert.ifError(err);
110110
console.log(keypair.private);
111111
console.log(keypair.public);
112-
console.log(keypair.fingerprint + '\n');
113-
console.log(keypair.randomart + '\n');
112+
console.log(keypair.fingerprint + "\n");
113+
console.log(keypair.randomart + "\n");
114114
});
115115
```
116116

examples/advanced.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
const assert = require("assert");
2-
const path = require("path");
3-
const tmpDir = require("os").tmpdir();
4-
const keygen = require("..");
1+
import assert from "assert";
2+
import keygen from "../index.js";
3+
import path from "path";
4+
import os from "os";
5+
6+
const tmpDir = os.tmpdir();
57

68
const opts = {
79
type: "rsa",

examples/simple.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
const assert = require("assert");
2-
const keygen = require("..");
1+
import assert from "assert";
2+
import keygen from "../index.js";
33

44
// generate a temporary keypair and return details
55
keygen((err, keypair) => {

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@andrewwlane/ssh-keygen2",
33
"type": "module",
4-
"version": "1.2.0",
4+
"version": "2.0.0",
55
"description": "Automate ssh-keygen command for generating RSA keypairs",
66
"main": "index.js",
77
"devDependencies": {
@@ -38,4 +38,4 @@
3838
"bugs": {
3939
"url": "https://github.com/AndrewLane/ssh-keygen2/issues"
4040
}
41-
}
41+
}

0 commit comments

Comments
 (0)