Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ npm install bitgesell-core --save

### Examples
#### Using network mode
The `network` will automatically determine the port to connect to, just like the `BGLd` and `bitcoin-cli` commands.
The `network` will automatically determine the port to connect to, just like the `BGLd` and `BGL-cli` commands.

```js
const Client = require('bitgesell-core');
Expand Down Expand Up @@ -140,10 +140,10 @@ Since Bitgesell Core v0.1.10, it's possible to manage multiple wallets using a s

Historically, the _accounts_ feature was supposed to offer similar functionality, but it has now been replaced by this more powerful feature.

To enable Multi Wallet support, start by specifying the number of added wallets you would like to have available and loaded on the server using the `-wallet` argument multiple times. For convenience, the bitgesell-core docker image will be used, but it's not a requirement:
To enable Multi Wallet support, start by specifying the number of added wallets you would like to have available and loaded on the server using the `-wallet` argument multiple times:

```sh
docker run --rm -it -p 18332:18332 ruimarinho/bitgesell-core:0.15-alpine \
bin/BGLd \
-printtoconsole \
-server \
-rpcauth='foo:e1fcea9fb59df8b0388f251984fe85$26431097d48c5b6047df8dee64f387f63835c01a2a463728ad75087d0133b8e6' \
Expand Down Expand Up @@ -219,12 +219,12 @@ To avoid potential issues with prototype references, all methods are still enume
Start the `BGLd` with the RPC server enabled and optionally configure a username and password:

```sh
docker run --rm -it ruimarinho/bitgesell-core:0.12-alpine -printtoconsole -rpcuser=foo -rpcpassword=bar -server
bin/BGLd -printtoconsole -rpcuser=foo -rpcpassword=bar -server
```

These configuration values may also be set on the `bitcoin.conf` file of your platform installation.
These configuration values may also be set on the `BGL.conf` file of your platform installation.

By default, port `8332` is used to listen for requests in `mainnet` mode, or `18332` in `testnet` and `regtest` modes (the regtest change will be changed to `18443` in [0.16](https://github.com/bitcoin/bitcoin/pull/10825)). Use the `network` property to initialize the client on the desired mode and automatically set the respective default port. You can optionally set a custom port of your choice too.
By default, port `8454` is used to listen for requests in `mainnet` mode, or `18332` in `testnet` mode. Use the `network` property to initialize the client on the desired mode and automatically set the respective default port. You can optionally set a custom port of your choice too.

The RPC services binds to the localhost loopback network interface, so use `rpcbind` to change where to bind to and `rpcallowip` to whitelist source IP access.

Expand Down Expand Up @@ -436,7 +436,7 @@ npm test

##
All contributions are welcome!
This is a fork of [bitcoin-core]() package
This is the Bitgesell RPC client maintained at [BitgesellOfficial/js-bitgesellcore-rpc](https://github.com/BitgesellOfficial/js-bitgesellcore-rpc). It is derived from the [bitcoin-core](https://github.com/ruimarinho/bitcoin-core) package.

## License
MIT
MIT
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"rest",
"rpc"
],
"homepage": "https://github.com/naftalimurgor/bitgesell-core",
"bugs": "https://github.com/naftalimurgor/bitgesell-core/issues",
"homepage": "https://github.com/BitgesellOfficial/js-bitgesellcore-rpc#readme",
"bugs": "https://github.com/BitgesellOfficial/js-bitgesellcore-rpc/issues",
"license": "MIT",
"author": {
"name": "Naftali Murgor",
Expand All @@ -20,10 +20,10 @@
"main": "src/index.js",
"repository": {
"type": "git",
"url": "https://github.com/naftalimurgor/bitgesell-core.git"
"url": "https://github.com/BitgesellOfficial/js-bitgesellcore-rpc.git"
},
"scripts": {
"changelog": "github_changelog_generator --project bitcoin-core --user ruimarinho --no-issues --header-label='# Changelog' --future-release=$npm_config_future_release && sed -i '' -e :a -e '$d;N;2,4ba' -e 'P;D' CHANGELOG.md",
"changelog": "github_changelog_generator --project js-bitgesellcore-rpc --user BitgesellOfficial --no-issues --header-label='# Changelog' --future-release=$npm_config_future_release && sed -i '' -e :a -e '$d;N;2,4ba' -e 'P;D' CHANGELOG.md",
"cover": "nyc --reporter=html --reporter=text npm test",
"dependencies": "docker-compose up -d BGLd BGLd-ssl BGLd-username-only",
"lint": "eslint src test",
Expand Down
48 changes: 48 additions & 0 deletions test/package_metadata_test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@

/**
* Module dependencies.
*/

const fs = require('fs');
const path = require('path');
const should = require('should');

/**
* Test package metadata and contributor-facing docs.
*/

describe('Package metadata', () => {
it('should point package metadata at the official Bitgesell RPC client repository', () => {
const metadata = require('../package.json'); // eslint-disable-line global-require
const lock = require('../package-lock.json'); // eslint-disable-line global-require

should(metadata.homepage).equal('https://github.com/BitgesellOfficial/js-bitgesellcore-rpc#readme');
should(metadata.bugs).equal('https://github.com/BitgesellOfficial/js-bitgesellcore-rpc/issues');
should(metadata.repository.url).equal('https://github.com/BitgesellOfficial/js-bitgesellcore-rpc.git');
should(lock.name).equal(metadata.name);
should(lock.version).equal(metadata.version);
should(lock.packages[''].name).equal(metadata.name);
should(lock.packages[''].version).equal(metadata.version);
});

it('should not document retired fork or Docker image URLs', done => {
fs.readFile(path.join(__dirname, '..', 'README.md'), 'utf8', (error, readme) => {
if (error) {
done(error);

return;
}

try {
should(readme).not.containEql('github.com/naftalimurgor/bitgesell-core');
should(readme).not.containEql('ruimarinho/bitgesell-core');
should(readme).containEql('BitgesellOfficial/js-bitgesellcore-rpc');
should(readme).containEql('port `8454`');
should(readme).containEql('`BGL.conf`');
done();
} catch (assertionError) {
done(assertionError);
}
});
});
});