Skip to content

Commit

Permalink
Move license and changelog to seperate files
Browse files Browse the repository at this point in the history
  • Loading branch information
AlCalzone committed May 5, 2018
1 parent 85755aa commit 07f3abf
Show file tree
Hide file tree
Showing 4 changed files with 156 additions and 156 deletions.
118 changes: 118 additions & 0 deletions CHANGELOG.md
@@ -0,0 +1,118 @@
# Changelog

## __WORK IN PROGRESS__
* (neophob) Include the hostname in the discovery response if present.
* (AlCalzone) Support programmatically rebooting and resetting the gateway.

## 1.1.2 (2018-05-01)
* (AlCalzone) Update CoAP and DTLS libraries so `node-aead-crypto` is no longer necessary on NodeJS 10+

## 1.0.1 (2018-04-27)
* (AlCalzone) Add support for NodeJS 10

## 1.0.0 (2018-04-19)
* (AlCalzone) Added tests for groups and scenes and fixed minor found bugs

## 0.13.0 (2018-04-17)
* (rogierhofboer) Detect lightbulb spectrum depending on its capabilities instead of the model name.

## 0.12.2 (2018-03-18)
* (AlCalzone) Automatic reconnection now restores observers

## 0.12.1 (2018-03-18)
* (AlCalzone) Added automatic retrying of the initial connection (if already authenticated)

## 0.12.0 (2018-03-17)
* (AlCalzone) Fix rounding and hue/saturation when using raw CoAP values
* (AlCalzone) Experimental support for automatic connection watching and reconnection

## 0.11.0 (2018-03-15) - WARNING: BREAKING CHANGES!
* (AlCalzone) **BREAKING**: The `connect()` method now either resolves with `true` or rejects with an error detailing why the connection failed.
* (AlCalzone) The error thrown by `authentication()` now correctly reflects why the authentication failed.
* (AlCalzone) Swallow `"DTLS handshake timed out"` promise rejections and emit an `"error"` instead

## 0.10.1 (2018-03-15)
* (AlCalzone) Ensure all changes are being sent when using the simplified API for groups.

## 0.10.0 (2018-03-15)
* (AlCalzone) Swallow `"CoapClient was reset"` promise rejections and emit an `"error"` instead
* (AlCalzone) Avoid sending `5712: null` in payloads when a group's transition time is `null` for some reason

## 0.9.1 (2018-03-09)
* (AlCalzone) Fix properties which are wrongly reported by the gateway

## 0.9.0 (2018-03-09)
* (neophob) Added gateway discovery
* (AlCalzone) Added timeout and tests for gateway discovery

## 0.8.7 (2018-03-08)
* (AlCalzone) Greatly enhanced test coverage
* (AlCalzone) Fixed some minor issues found by the new tests

## 0.8.6 (2018-03-07)
* (AlCalzone) Published bugfixes that should have been live already.

## 0.8.5 (2018-02-27)
* (AlCalzone) Updated `node-coap-client`

## 0.8.4 (2018-02-23)
* (AlCalzone) Fixed `Group.activateScene` when the scene was already selected

## 0.8.3 (2018-02-22)
* (AlCalzone) Removed the recently-added payload merging because it did more harm than good
* (AlCalzone) Fixed `Group.activateScene` when the lights are turned off

## 0.8.2 (2018-02-19)
* (AlCalzone) Force `hue` and `saturation` to appear in pairs in the sent payload

## 0.8.1 (2018-02-15)
* (AlCalzone) Support floating point numbers as property values

## 0.8.0 (2018-02-15)
* (AlCalzone) Use the `hue` and `saturation` CoAP properties directly instead of `colorX/Y`

## 0.7.2 (2018-02-07)
* (AlCalzone) Attempt to fix `TypeError: generator already running` in ioBroker.tradfri

## 0.7.1 (2018-02-06)
* (AlCalzone) Update coap/dtls libs: Fixed an error in the cipher suite definitions

## 0.7.0 (2018-01-28)
* (AlCalzone) Support using raw CoAP values instead of the simplified scales for many properties.

## 0.6.0 (2018-01-13)
* (AlCalzone) Use the `colorTemperature` CoAP property directly instead of `colorX/Y`

## 0.5.6 (2018-01-10)
* (AlCalzone) Added stub property for IPSO key `5717` in Light objects to remove warnings for Gateway v1.3.14

## 0.5.5 (2017-12-25)
* (AlCalzone) Fixed a null reference in `observeGroups_callback()`

## 0.5.4 (2017-12-25)
* (AlCalzone) Update `node-coap-client` dependency to support receiving block-wise messages.

## 0.5.3 (2017-12-01)
* (AlCalzone) Allow calling `setColor()` for white spectrum bulbs with `f5faf6`, `f1e0b5` and `efd275`

## 0.5.1 (2017-12-01)
* (AlCalzone) Fixed a bug where the simplified light API would not always send the correct payloads.

## 0.5.0 (2017-11-20)
* (AlCalzone) Fixed some checks in the simplified API for lights
* (AlCalzone) The promises returned by `observeDevices` and `observeGroupsAndScenes` now only resolve after all devices or groups and scenes have been received

## 0.4.1 (2017-11-07)
* (AlCalzone) Simplified operating groups

## 0.4.0 (2017-11-04)
* (AlCalzone) Reworked the observe api so it resides on TradfriClient now
* (AlCalzone) Simplified operating lights

## 0.3.0 (2017-11-02)
* (AlCalzone) Changed authentication procedure to comply with IKEA's request
* (AlCalzone) Round brightness up, so that 1 => 1%, not 0%

## 0.2.0
* (AlCalzone) first working release

21 changes: 21 additions & 0 deletions LICENSE
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2017 AlCalzone <d.griesel@gmx.net>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
145 changes: 3 additions & 142 deletions README.md
Expand Up @@ -6,6 +6,9 @@ Library to talk to IKEA Trådfri Gateways without external binaries
[![Build Status](https://img.shields.io/circleci/project/github/AlCalzone/node-tradfri-client.svg)](https://circleci.com/gh/AlCalzone/node-tradfri-client)
[![Coverage Status](https://img.shields.io/coveralls/github/AlCalzone/node-tradfri-client.svg)](https://coveralls.io/github/AlCalzone/node-tradfri-client)

* [License](LICENSE)
* [Changelog](CHANGELOG.md)

## Example usage

### Discover a Gateway
Expand Down Expand Up @@ -656,145 +659,3 @@ All parameters of this object are optional and use the default values if not pro
**Note:** Reconnection internally calls the `reset()` method. This means pending connections and promises will be dropped and the `"error"` event may be emitted aswell. See [resetting the connection](#resetting-the-connection) for details.

The automatic reconnection tries to restore all previously defined observers as soon as the connection is alive again.

## Changelog

#### __WORK IN PROGRESS__
* (neophob) Include the hostname in the discovery response if present.
* (AlCalzone) Support programmatically rebooting and resetting the gateway.

#### 1.1.2 (2018-05-01)
* (AlCalzone) Update CoaP and DTLS libraries so `node-aead-crypto` is no longer necessary on NodeJS 10+

#### 1.0.1 (2018-04-27)
* (AlCalzone) Add support for NodeJS 10

#### 1.0.0 (2018-04-19)
* (AlCalzone) Added tests for groups and scenes and fixed minor found bugs

#### 0.13.0 (2018-04-17)
* (rogierhofboer) Detect lightbulb spectrum depending on its capabilities instead of the model name.

#### 0.12.2 (2018-03-18)
* (AlCalzone) Automatic reconnection now restores observers

#### 0.12.1 (2018-03-18)
* (AlCalzone) Added automatic retrying of the initial connection (if already authenticated)

#### 0.12.0 (2018-03-17)
* (AlCalzone) Fix rounding and hue/saturation when using raw CoAP values
* (AlCalzone) Experimental support for automatic connection watching and reconnection

#### 0.11.0 (2018-03-15) - WARNING: BREAKING CHANGES!
* (AlCalzone) **BREAKING**: The `connect()` method now either resolves with `true` or rejects with an error detailing why the connection failed.
* (AlCalzone) The error thrown by `authentication()` now correctly reflects why the authentication failed.
* (AlCalzone) Swallow `"DTLS handshake timed out"` promise rejections and emit an `"error"` instead

#### 0.10.1 (2018-03-15)
* (AlCalzone) Ensure all changes are being sent when using the simplified API for groups.

#### 0.10.0 (2018-03-15)
* (AlCalzone) Swallow `"CoapClient was reset"` promise rejections and emit an `"error"` instead
* (AlCalzone) Avoid sending `5712: null` in payloads when a group's transition time is `null` for some reason

#### 0.9.1 (2018-03-09)
* (AlCalzone) Fix properties which are wrongly reported by the gateway

#### 0.9.0 (2018-03-09)
* (neophob) Added gateway discovery
* (AlCalzone) Added timeout and tests for gateway discovery

#### 0.8.7 (2018-03-08)
* (AlCalzone) Greatly enhanced test coverage
* (AlCalzone) Fixed some minor issues found by the new tests

#### 0.8.6 (2018-03-07)
* (AlCalzone) Published bugfixes that should have been live already.

#### 0.8.5 (2018-02-27)
* (AlCalzone) Updated `node-coap-client`

#### 0.8.4 (2018-02-23)
* (AlCalzone) Fixed `Group.activateScene` when the scene was already selected

#### 0.8.3 (2018-02-22)
* (AlCalzone) Removed the recently-added payload merging because it did more harm than good
* (AlCalzone) Fixed `Group.activateScene` when the lights are turned off

#### 0.8.2 (2018-02-19)
* (AlCalzone) Force `hue` and `saturation` to appear in pairs in the sent payload

#### 0.8.1 (2018-02-15)
* (AlCalzone) Support floating point numbers as property values

#### 0.8.0 (2018-02-15)
* (AlCalzone) Use the `hue` and `saturation` CoAP properties directly instead of `colorX/Y`

#### 0.7.2 (2018-02-07)
* (AlCalzone) Attempt to fix `TypeError: generator already running` in ioBroker.tradfri

#### 0.7.1 (2018-02-06)
* (AlCalzone) Update coap/dtls libs: Fixed an error in the cipher suite definitions

#### 0.7.0 (2018-01-28)
* (AlCalzone) Support using raw CoAP values instead of the simplified scales for many properties.

#### 0.6.0 (2018-01-13)
* (AlCalzone) Use the `colorTemperature` CoAP property directly instead of `colorX/Y`

#### 0.5.6 (2018-01-10)
* (AlCalzone) Added stub property for IPSO key `5717` in Light objects to remove warnings for Gateway v1.3.14

#### 0.5.5 (2017-12-25)
* (AlCalzone) Fixed a null reference in `observeGroups_callback()`

#### 0.5.4 (2017-12-25)
* (AlCalzone) Update `node-coap-client` dependency to support receiving block-wise messages.

#### 0.5.3 (2017-12-01)
* (AlCalzone) Allow calling `setColor()` for white spectrum bulbs with `f5faf6`, `f1e0b5` and `efd275`

#### 0.5.1 (2017-12-01)
* (AlCalzone) Fixed a bug where the simplified light API would not always send the correct payloads.

#### 0.5.0 (2017-11-20)
* (AlCalzone) Fixed some checks in the simplified API for lights
* (AlCalzone) The promises returned by `observeDevices` and `observeGroupsAndScenes` now only resolve after all devices or groups and scenes have been received

#### 0.4.1 (2017-11-07)
* (AlCalzone) Simplified operating groups

#### 0.4.0 (2017-11-04)
* (AlCalzone) Reworked the observe api so it resides on TradfriClient now
* (AlCalzone) Simplified operating lights

#### 0.3.0 (2017-11-02)
* (AlCalzone) Changed authentication procedure to comply with IKEA's request
* (AlCalzone) Round brightness up, so that 1 => 1%, not 0%

#### 0.2.0
* (AlCalzone) first working release


## License
The MIT License (MIT)

Copyright (c) 2017 AlCalzone <d.griesel@gmx.net>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
28 changes: 14 additions & 14 deletions maintenance/release.ts
Expand Up @@ -11,8 +11,8 @@
or
npm run release -- <version> [--dry]
PLACEHOLDER for next version in readme:
#### __WORK IN PROGRESS__
PLACEHOLDER for next version in changelog:
## __WORK IN PROGRESS__
*/

Expand All @@ -36,17 +36,17 @@ function fail(reason: string) {

const packPath = path.join(rootDir, "package.json");
const pack = require(packPath);
const readmePath = path.join(rootDir, "README.md");
let readme = fs.readFileSync(readmePath, "utf8");
const README_PLACEHOLDER = "#### __WORK IN PROGRESS__";
const changelogPath = path.join(rootDir, "CHANGELOG.md");
let changelog = fs.readFileSync(changelogPath, "utf8");
const CHANGELOG_PLACEHOLDER = "## __WORK IN PROGRESS__";

// check if the readme contains exactly 1 occurence of the changelog placeholder
switch ((readme.match(new RegExp("^" + README_PLACEHOLDER + "$", "gm")) || []).length) {
// check if the changelog contains exactly 1 occurence of the changelog placeholder
switch ((changelog.match(new RegExp("^" + CHANGELOG_PLACEHOLDER + "$", "gm")) || []).length) {
case 0:
fail(colors.red("Cannot continue, the changelog placeholder is missing from the readme!"));
fail(colors.red("Cannot continue, the changelog placeholder is missing from CHANGELOG.md!"));
case 1: break; // all good
default:
fail(colors.red("Cannot continue, there is more than one changelog placeholder in the readme!"));
fail(colors.red("Cannot continue, there is more than one changelog placeholder in CHANGELOG.md!"));
}

// check if there are untracked changes
Expand Down Expand Up @@ -102,13 +102,13 @@ if (argv.dry) {
pack.version = newVersion;
fs.writeFileSync(packPath, JSON.stringify(pack, null, 2));

console.log(`updating changelog in README.md`);
console.log(`updating CHANGELOG.md`);
const d = new Date();
readme = readme.replace(
README_PLACEHOLDER,
`#### ${newVersion} (${d.getFullYear()}-${padStart("" + (d.getMonth() + 1), 2, "0")}-${padStart("" + d.getDate(), 2, "0")})`,
changelog = changelog.replace(
CHANGELOG_PLACEHOLDER,
`## ${newVersion} (${d.getFullYear()}-${padStart("" + (d.getMonth() + 1), 2, "0")}-${padStart("" + d.getDate(), 2, "0")})`,
);
fs.writeFileSync(readmePath, readme, "utf8");
fs.writeFileSync(changelogPath, changelog, "utf8");

// console.log(`updating io-package.json from ${colors.blue(ioPack.common.version)} to ${colors.green(newVersion)}`);
// ioPack.common.version = newVersion;
Expand Down

0 comments on commit 07f3abf

Please sign in to comment.