Merge pull request #7136
fa19a58
HelpMessage: Don't hide -mintxfee behind showDebug (MarcoFalke)faffc17
rpcwallet: Clarify what settxfee does (MarcoFalke)9999cb0
Fix url in .travis.yml (MarcoFalke)fa22a10
contrib: Del. gitian downloader config and update gitian README (MarcoFalke)fad3035
[doc] Minor markdown fixes (MarcoFalke)
This commit is contained in:
commit
8f761e87c3
@ -2,7 +2,7 @@
|
|||||||
# - A travis bug causes caches to trample eachother when using the same
|
# - A travis bug causes caches to trample eachother when using the same
|
||||||
# compiler key (which we don't use anyway). This is worked around for now by
|
# compiler key (which we don't use anyway). This is worked around for now by
|
||||||
# replacing the "compilers" with a build name prefixed by the no-op ":"
|
# replacing the "compilers" with a build name prefixed by the no-op ":"
|
||||||
# command. See: https://github.com/travis-ci/casher/issues/6
|
# command. See: https://github.com/travis-ci/travis-ci/issues/4393
|
||||||
|
|
||||||
os: linux
|
os: linux
|
||||||
language: cpp
|
language: cpp
|
||||||
|
@ -48,7 +48,7 @@ lots of money.
|
|||||||
|
|
||||||
### Automated Testing
|
### Automated Testing
|
||||||
|
|
||||||
Developers are strongly encouraged to write unit tests for new code, and to
|
Developers are strongly encouraged to write [unit tests](/doc/unit-tests.md) for new code, and to
|
||||||
submit new unit tests for old code. Unit tests can be compiled and run
|
submit new unit tests for old code. Unit tests can be compiled and run
|
||||||
(assuming they weren't disabled in configure) with: `make check`
|
(assuming they weren't disabled in configure) with: `make check`
|
||||||
|
|
||||||
|
@ -1,8 +1,7 @@
|
|||||||
### Gavin's notes on getting gitian builds up and running using KVM:###
|
### Gavin's notes on getting gitian builds up and running using KVM
|
||||||
|
|
||||||
These instructions distilled from:
|
These instructions distilled from
|
||||||
[ https://help.ubuntu.com/community/KVM/Installation]( https://help.ubuntu.com/community/KVM/Installation)
|
[https://help.ubuntu.com/community/KVM/Installation](https://help.ubuntu.com/community/KVM/Installation).
|
||||||
... see there for complete details.
|
|
||||||
|
|
||||||
You need the right hardware: you need a 64-bit-capable CPU with hardware virtualization support (Intel VT-x or AMD-V). Not all modern CPUs support hardware virtualization.
|
You need the right hardware: you need a 64-bit-capable CPU with hardware virtualization support (Intel VT-x or AMD-V). Not all modern CPUs support hardware virtualization.
|
||||||
|
|
||||||
@ -33,14 +32,14 @@ Once you've got the right hardware and software:
|
|||||||
# Get inputs (see doc/release-process.md for exact inputs needed and where to get them)
|
# Get inputs (see doc/release-process.md for exact inputs needed and where to get them)
|
||||||
...
|
...
|
||||||
|
|
||||||
# For further build instructions see doc/release-notes.md
|
# For further build instructions see doc/release-process.md
|
||||||
...
|
...
|
||||||
|
|
||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
`gitian-builder` now also supports building using LXC. See
|
`gitian-builder` now also supports building using LXC. See
|
||||||
[ https://help.ubuntu.com/12.04/serverguide/lxc.html]( https://help.ubuntu.com/12.04/serverguide/lxc.html)
|
[help.ubuntu.com](https://help.ubuntu.com/14.04/serverguide/lxc.html)
|
||||||
... for how to get LXC up and running under Ubuntu.
|
for how to get LXC up and running under Ubuntu.
|
||||||
|
|
||||||
If your main machine is a 64-bit Mac or PC with a few gigabytes of memory
|
If your main machine is a 64-bit Mac or PC with a few gigabytes of memory
|
||||||
and at least 10 gigabytes of free disk space, you can `gitian-build` using
|
and at least 10 gigabytes of free disk space, you can `gitian-build` using
|
||||||
|
@ -1,45 +0,0 @@
|
|||||||
---
|
|
||||||
name: bitcoin
|
|
||||||
urls:
|
|
||||||
- http://bitcoin.org/bitcoin-latest-linux-gitian.zip
|
|
||||||
rss:
|
|
||||||
- url:
|
|
||||||
xpath: //item/link/text()
|
|
||||||
pattern: bitcoin-\d+.\d+.\d+-linux-gitian.zip
|
|
||||||
signers:
|
|
||||||
0A82509767C7D4A5D14DA2301AE1D35043E08E54:
|
|
||||||
name: BlueMatt
|
|
||||||
key: bluematt
|
|
||||||
BF6273FAEF7CC0BA1F562E50989F6B3048A116B5:
|
|
||||||
name: Devrandom
|
|
||||||
key: devrandom
|
|
||||||
E463A93F5F3117EEDE6C7316BD02942421F4889F:
|
|
||||||
name: Luke-Jr
|
|
||||||
key: luke-jr
|
|
||||||
D762373D24904A3E42F33B08B9A408E71DAAC974:
|
|
||||||
name: "Pieter Wuille"
|
|
||||||
key: sipa
|
|
||||||
77E72E69DA7EE0A148C06B21B34821D4944DE5F7:
|
|
||||||
name: tcatm
|
|
||||||
key: tcatm
|
|
||||||
01CDF4627A3B88AAE4A571C87588242FBE38D3A8:
|
|
||||||
name: "Gavin Andresen"
|
|
||||||
key: gavinandresen
|
|
||||||
71A3B16735405025D447E8F274810B012346C9A6:
|
|
||||||
name: "Wladimir J. van der Laan"
|
|
||||||
key: laanwj
|
|
||||||
AEC1884398647C47413C1C3FB1179EB7347DC10D:
|
|
||||||
name: "Warren Togami"
|
|
||||||
key: wtogami
|
|
||||||
9692B91BBF0E8D34DFD33B1882C5C009628ECF0C:
|
|
||||||
name: michagogo
|
|
||||||
key: michagogo
|
|
||||||
E944AE667CF960B1004BC32FCA662BE18B877A60:
|
|
||||||
name: "Andreas Schildbach"
|
|
||||||
key: aschildbach
|
|
||||||
C060A6635913D98A3587D7DB1C2491FFEB0EF770:
|
|
||||||
name: "Cory Fields"
|
|
||||||
key: "cfields"
|
|
||||||
37EC7D7B0A217CDB4B4E007E7FAB114267E4FA04:
|
|
||||||
name: "Peter Todd"
|
|
||||||
key: "petertodd"
|
|
@ -1,45 +0,0 @@
|
|||||||
---
|
|
||||||
name: bitcoin
|
|
||||||
urls:
|
|
||||||
- http://bitcoin.org/bitcoin-latest-win32-gitian.zip
|
|
||||||
rss:
|
|
||||||
- url:
|
|
||||||
xpath: //item/link/text()
|
|
||||||
pattern: bitcoin-\d+.\d+.\d+-win32-gitian.zip
|
|
||||||
signers:
|
|
||||||
0A82509767C7D4A5D14DA2301AE1D35043E08E54:
|
|
||||||
name: BlueMatt
|
|
||||||
key: bluematt
|
|
||||||
BF6273FAEF7CC0BA1F562E50989F6B3048A116B5:
|
|
||||||
name: Devrandom
|
|
||||||
key: devrandom
|
|
||||||
E463A93F5F3117EEDE6C7316BD02942421F4889F:
|
|
||||||
name: Luke-Jr
|
|
||||||
key: luke-jr
|
|
||||||
D762373D24904A3E42F33B08B9A408E71DAAC974:
|
|
||||||
name: "Pieter Wuille"
|
|
||||||
key: sipa
|
|
||||||
77E72E69DA7EE0A148C06B21B34821D4944DE5F7:
|
|
||||||
name: tcatm
|
|
||||||
key: tcatm
|
|
||||||
01CDF4627A3B88AAE4A571C87588242FBE38D3A8:
|
|
||||||
name: "Gavin Andresen"
|
|
||||||
key: gavinandresen
|
|
||||||
71A3B16735405025D447E8F274810B012346C9A6:
|
|
||||||
name: "Wladimir J. van der Laan"
|
|
||||||
key: laanwj
|
|
||||||
AEC1884398647C47413C1C3FB1179EB7347DC10D:
|
|
||||||
name: "Warren Togami"
|
|
||||||
key: wtogami
|
|
||||||
9692B91BBF0E8D34DFD33B1882C5C009628ECF0C:
|
|
||||||
name: michagogo
|
|
||||||
key: michagogo
|
|
||||||
E944AE667CF960B1004BC32FCA662BE18B877A60:
|
|
||||||
name: "Andreas Schildbach"
|
|
||||||
key: aschildbach
|
|
||||||
C060A6635913D98A3587D7DB1C2491FFEB0EF770:
|
|
||||||
name: "Cory Fields"
|
|
||||||
key: "cfields"
|
|
||||||
37EC7D7B0A217CDB4B4E007E7FAB114267E4FA04:
|
|
||||||
name: "Peter Todd"
|
|
||||||
key: "petertodd"
|
|
@ -218,7 +218,7 @@ General Bitcoin Core
|
|||||||
- *Rationale*: RPC allows for better automatic testing. The test suite for
|
- *Rationale*: RPC allows for better automatic testing. The test suite for
|
||||||
the GUI is very limited
|
the GUI is very limited
|
||||||
|
|
||||||
- Make sure pulls pass Travis CI before merging
|
- Make sure pull requests pass Travis CI before merging
|
||||||
|
|
||||||
- *Rationale*: Makes sure that they pass thorough testing, and that the tester will keep passing
|
- *Rationale*: Makes sure that they pass thorough testing, and that the tester will keep passing
|
||||||
on the master branch. Otherwise all new pull requests will start failing the tests, resulting in
|
on the master branch. Otherwise all new pull requests will start failing the tests, resulting in
|
||||||
@ -230,9 +230,9 @@ General Bitcoin Core
|
|||||||
Wallet
|
Wallet
|
||||||
-------
|
-------
|
||||||
|
|
||||||
- Make sure that that no crashes happen with run-time option `-disablewallet`.
|
- Make sure that no crashes happen with run-time option `-disablewallet`.
|
||||||
|
|
||||||
- *Rationale*: In RPC code that conditionally use the wallet (such as
|
- *Rationale*: In RPC code that conditionally uses the wallet (such as
|
||||||
`validateaddress`) it is easy to forget that global pointer `pwalletMain`
|
`validateaddress`) it is easy to forget that global pointer `pwalletMain`
|
||||||
can be NULL. See `qa/rpc-tests/disablewallet.py` for functional tests
|
can be NULL. See `qa/rpc-tests/disablewallet.py` for functional tests
|
||||||
exercising the API with `-disablewallet`
|
exercising the API with `-disablewallet`
|
||||||
@ -250,9 +250,9 @@ General C++
|
|||||||
with assertions disabled, having side-effects in assertions is unexpected and
|
with assertions disabled, having side-effects in assertions is unexpected and
|
||||||
makes the code harder to understand
|
makes the code harder to understand
|
||||||
|
|
||||||
- If you use the .h, you must link the .cpp
|
- If you use the `.h`, you must link the `.cpp`
|
||||||
|
|
||||||
- *Rationale*: Include files are the interface for the implementation file. Including one but
|
- *Rationale*: Include files define the interface for the code in implementation files. Including one but
|
||||||
not linking the other is confusing. Please avoid that. Moving functions from
|
not linking the other is confusing. Please avoid that. Moving functions from
|
||||||
the `.h` to the `.cpp` should not result in build errors
|
the `.h` to the `.cpp` should not result in build errors
|
||||||
|
|
||||||
@ -264,11 +264,11 @@ General C++
|
|||||||
C++ data structures
|
C++ data structures
|
||||||
--------------------
|
--------------------
|
||||||
|
|
||||||
- Never use the std::map [] syntax when reading from a map, but instead use .find()
|
- Never use the `std::map []` syntax when reading from a map, but instead use `.find()`
|
||||||
|
|
||||||
- *Rationale*: [] does an insert (of the default element) if the item doesn't
|
- *Rationale*: `[]` does an insert (of the default element) if the item doesn't
|
||||||
exist in the map yet. This has resulted in memory leaks in the past, as well as
|
exist in the map yet. This has resulted in memory leaks in the past, as well as
|
||||||
race conditions (expecting read-read behavior). Using [] is fine for *writing* to a map
|
race conditions (expecting read-read behavior). Using `[]` is fine for *writing* to a map
|
||||||
|
|
||||||
- Do not compare an iterator from one data structure with an iterator of
|
- Do not compare an iterator from one data structure with an iterator of
|
||||||
another data structure (even if of the same type)
|
another data structure (even if of the same type)
|
||||||
@ -304,18 +304,18 @@ C++ data structures
|
|||||||
Strings and formatting
|
Strings and formatting
|
||||||
------------------------
|
------------------------
|
||||||
|
|
||||||
- Be careful of LogPrint versus LogPrintf. LogPrint takes a 'category' argument, LogPrintf does not.
|
- Be careful of `LogPrint` versus `LogPrintf`. `LogPrint` takes a `category` argument, `LogPrintf` does not.
|
||||||
|
|
||||||
- *Rationale*: Confusion of these can result in runtime exceptions due to
|
- *Rationale*: Confusion of these can result in runtime exceptions due to
|
||||||
formatting mismatch, and it is easy to get wrong because of subtly similar naming
|
formatting mismatch, and it is easy to get wrong because of subtly similar naming
|
||||||
|
|
||||||
- Use std::string, avoid C string manipulation functions
|
- Use `std::string`, avoid C string manipulation functions
|
||||||
|
|
||||||
- *Rationale*: C++ string handling is marginally safer, less scope for
|
- *Rationale*: C++ string handling is marginally safer, less scope for
|
||||||
buffer overflows and surprises with \0 characters. Also some C string manipulations
|
buffer overflows and surprises with `\0` characters. Also some C string manipulations
|
||||||
tend to act differently depending on platform, or even the user locale
|
tend to act differently depending on platform, or even the user locale
|
||||||
|
|
||||||
- Use ParseInt32, ParseInt64, ParseDouble from `utilstrencodings.h` for number parsing
|
- Use `ParseInt32`, `ParseInt64`, `ParseDouble` from `utilstrencodings.h` for number parsing
|
||||||
|
|
||||||
- *Rationale*: These functions do overflow checking, and avoid pesky locale issues
|
- *Rationale*: These functions do overflow checking, and avoid pesky locale issues
|
||||||
|
|
||||||
|
@ -1,18 +1,18 @@
|
|||||||
Compiling/running unit tests
|
Compiling/running unit tests
|
||||||
------------------------------------
|
------------------------------------
|
||||||
|
|
||||||
Unit tests will be automatically compiled if dependencies were met in configure
|
Unit tests will be automatically compiled if dependencies were met in `./configure`
|
||||||
and tests weren't explicitly disabled.
|
and tests weren't explicitly disabled.
|
||||||
|
|
||||||
After configuring, they can be run with 'make check'.
|
After configuring, they can be run with `make check`.
|
||||||
|
|
||||||
To run the bitcoind tests manually, launch src/test/test_bitcoin .
|
To run the bitcoind tests manually, launch `src/test/test_bitcoin`.
|
||||||
|
|
||||||
To add more bitcoind tests, add `BOOST_AUTO_TEST_CASE` functions to the existing
|
To add more bitcoind tests, add `BOOST_AUTO_TEST_CASE` functions to the existing
|
||||||
.cpp files in the test/ directory or add new .cpp files that
|
.cpp files in the `test/` directory or add new .cpp files that
|
||||||
implement new BOOST_AUTO_TEST_SUITE sections.
|
implement new BOOST_AUTO_TEST_SUITE sections.
|
||||||
|
|
||||||
To run the bitcoin-qt tests manually, launch src/qt/test/test_bitcoin-qt
|
To run the bitcoin-qt tests manually, launch `src/qt/test/test_bitcoin-qt`
|
||||||
|
|
||||||
To add more bitcoin-qt tests, add them to the `src/qt/test/` directory and
|
To add more bitcoin-qt tests, add them to the `src/qt/test/` directory and
|
||||||
the `src/qt/test/test_main.cpp` file.
|
the `src/qt/test/test_main.cpp` file.
|
||||||
|
@ -393,8 +393,7 @@ std::string HelpMessage(HelpMessageMode mode)
|
|||||||
strUsage += HelpMessageGroup(_("Wallet options:"));
|
strUsage += HelpMessageGroup(_("Wallet options:"));
|
||||||
strUsage += HelpMessageOpt("-disablewallet", _("Do not load the wallet and disable wallet RPC calls"));
|
strUsage += HelpMessageOpt("-disablewallet", _("Do not load the wallet and disable wallet RPC calls"));
|
||||||
strUsage += HelpMessageOpt("-keypool=<n>", strprintf(_("Set key pool size to <n> (default: %u)"), DEFAULT_KEYPOOL_SIZE));
|
strUsage += HelpMessageOpt("-keypool=<n>", strprintf(_("Set key pool size to <n> (default: %u)"), DEFAULT_KEYPOOL_SIZE));
|
||||||
if (showDebug)
|
strUsage += HelpMessageOpt("-mintxfee=<amt>", strprintf(_("Fees (in %s/kB) smaller than this are considered zero fee for transaction creation (default: %s)"),
|
||||||
strUsage += HelpMessageOpt("-mintxfee=<amt>", strprintf("Fees (in %s/kB) smaller than this are considered zero fee for transaction creation (default: %s)",
|
|
||||||
CURRENCY_UNIT, FormatMoney(DEFAULT_TRANSACTION_MINFEE)));
|
CURRENCY_UNIT, FormatMoney(DEFAULT_TRANSACTION_MINFEE)));
|
||||||
strUsage += HelpMessageOpt("-paytxfee=<amt>", strprintf(_("Fee (in %s/kB) to add to transactions you send (default: %s)"),
|
strUsage += HelpMessageOpt("-paytxfee=<amt>", strprintf(_("Fee (in %s/kB) to add to transactions you send (default: %s)"),
|
||||||
CURRENCY_UNIT, FormatMoney(payTxFee.GetFeePerK())));
|
CURRENCY_UNIT, FormatMoney(payTxFee.GetFeePerK())));
|
||||||
|
@ -2178,7 +2178,7 @@ UniValue settxfee(const UniValue& params, bool fHelp)
|
|||||||
if (fHelp || params.size() < 1 || params.size() > 1)
|
if (fHelp || params.size() < 1 || params.size() > 1)
|
||||||
throw runtime_error(
|
throw runtime_error(
|
||||||
"settxfee amount\n"
|
"settxfee amount\n"
|
||||||
"\nSet the transaction fee per kB.\n"
|
"\nSet the transaction fee per kB. Overwrites the paytxfee parameter.\n"
|
||||||
"\nArguments:\n"
|
"\nArguments:\n"
|
||||||
"1. amount (numeric, required) The transaction fee in " + CURRENCY_UNIT + "/kB rounded to the nearest 0.00000001\n"
|
"1. amount (numeric, required) The transaction fee in " + CURRENCY_UNIT + "/kB rounded to the nearest 0.00000001\n"
|
||||||
"\nResult\n"
|
"\nResult\n"
|
||||||
|
Loading…
Reference in New Issue
Block a user