move dfhack.history to dfhack-config/dfhack.history

develop
myk002 2022-07-23 21:55:49 -07:00
parent 2ed93418d2
commit 5f56d79235
No known key found for this signature in database
GPG Key ID: 8A39CA0FA0C16E78
5 changed files with 61 additions and 43 deletions

@ -1,6 +1,5 @@
debug
=====
Tags:
:dfhack-keybind:`debugfilter`
@ -37,36 +36,37 @@ printing level selection.
Usage:
- ``debugfilter category [<plugin regex>] [<category regex>]``
``debugfilter category [<plugin regex>] [<category regex>]``
List available debug plugin and category names. If filters aren't givenm
then all plugins/categories are matched. This command is a good way to test
regex parameters before you pass them to ``set``.
- ``debugfilter filter [<id>]``
``debugfilter filter [<id>]``
List active and passive debug print level changes. The optional ``id``
parameter is the id listed as first column in the filter list. If ``id`` is
given, then the command shows extended information for the given filter
only.
- ``debugfilter set [<level>] [<plugin regex>] [<category regex>]``
``debugfilter set [<level>] [<plugin regex>] [<category regex>]``
Create a new debug filter to set category verbosity levels. This filter
will not be saved when the DF process exists or the plugin is unloaded.
- ``debugfilter set persistent [<level>] [<plugin regex>] [<category regex>]``
``debugfilter set persistent [<level>] [<plugin regex>] [<category regex>]``
Store the filter in the configuration file to until ``unset`` is used to
remove it.
- ``debugfilter unset <id> [<id> ...]``
``debugfilter unset <id> [<id> ...]``
Delete a space separated list of filters.
- ``debugfilter disable <id> [<id> ...]``
``debugfilter disable <id> [<id> ...]``
Disable a space separated list of filters but keep it in the filter list.
- ``debugfilter enable <id> [<id> ...]``
``debugfilter enable <id> [<id> ...]``
Enable a space sperate list of filters.
- ``debugfilter header [enable] | [disable] [<element> ...]``
``debugfilter header [enable] | [disable] [<element> ...]``
Control which header metadata is shown along with each log message. Run it
without parameters to see the list of configurable elements. Include an
``enable`` or ``disable`` keyword to change whether specific elements are
shown.
Examples:
Example
-------
- ``debugfilter set Warning core script``
``debugfilter set Warning core script``
Hide script execution log messages (e.g. "Loading script:
dfhack-config/dfhack.init"), which are normally output at Info verbosity
in the "core" plugin with the "script" category.

@ -1,6 +1,5 @@
deramp
======
Tags:
:dfhack-keybind:`deramp`

@ -1,6 +1,5 @@
dig-now
=======
Tags:
:dfhack-keybind:`dig-now`
@ -33,31 +32,33 @@ Any ``<pos>`` parameters can either be an ``<x>,<y>,<z>`` triple (e.g.
game cursor should be used. You can use the `position` command to get the
current cursor position if you need it.
Examples:
Examples
--------
- ``dig-now``
``dig-now``
Dig designated tiles according to standard game rules.
- ``dig-now --clean``
``dig-now --clean``
Dig all designated tiles, but don't generate any boulders, ores, or gems.
- ``dig-now --dump here``
``dig-now --dump here``
Dig tiles and teleport all generated boulders, ores, and gems to the tile
under the game cursor.
Options:
Options
-------
- ``-c``, ``--clean``
``-c``, ``--clean``
Don't generate any boulders, ores, or gems. Equivalent to
``--percentages 0,0,0,0``.
- ``-d``, ``--dump <pos>``
``-d``, ``--dump <pos>``
Dump any generated items at the specified coordinates. If the tile at those
coordinates is open space or is a wall, items will be generated on the
closest walkable tile below.
- ``-e``, ``--everywhere``
``-e``, ``--everywhere``
Generate a boulder, ore, or gem for every tile that can produce one.
Equivalent to ``--percentages 100,100,100,100``.
- ``-p``, ``--percentages <layer>,<vein>,<small cluster>,<deep>``
``-p``, ``--percentages <layer>,<vein>,<small cluster>,<deep>``
Set item generation percentages for each of the tile categories. The
``vein`` category includes both the large oval clusters and the long stringy
mineral veins. Default is ``25,33,100,100``.
- ``-z``, ``--cur-zlevel``
``-z``, ``--cur-zlevel``
Restricts the bounds to the currently visible z-level.

@ -3,17 +3,39 @@
dig
===
This plugin makes many automated or complicated dig patterns easy.
Basic commands:
:digv: Designate all of the selected vein for digging.
:digvx: Also cross z-levels, digging stairs as needed. Alias for ``digv x``.
:digl: Like ``digv``, for layer stone. Also supports an ``undo`` option
to remove designations, for if you accidentally set 50 levels at once.
:diglx: Also cross z-levels, digging stairs as needed. Alias for ``digl x``.
Tags:
:dfhack-keybind:`digv`
:dfhack-keybind:`digvx`
:dfhack-keybind:`digl`
:dfhack-keybind:`diglx`
:dfhack-keybind:`digcircle`
:dfhack-keybind:`digtype`
:dfhack-keybind:`digexp`
Make complicated dig patterns easy.
Usage:
``digv [x] [-p<number>]``
Designate all of the selected vein for digging.
``digvx [-p<number>]``
Also cross z-levels, digging stairs as needed. Alias for ``digv x``.
``digl [x] [undo] [-p<number>]``
Like ``digv``, for layer stone. If ``undo`` is specified, removes the
layer designation instead (for if you accidentally set 50 levels at once).
``diglx [-p<number>]``
Also cross z-levels, digging stairs as needed. Alias for ``digl x``.
``digcircle [<diameter>] [<solidity>] [<action>] [<designation>] [-p<number>]``
Designate circles. The diameter is the number of tiles across the center of
the circle that you want to dig. See the `digcircle`_ section below for an
explanation of the options.
``digtype [<designation>]
For every tile on the map of the same vein type as the selected tile,
this command designates it to have the same designation as the
selected tile. If the selected tile has no designation, they will be
dig designated.
``digexp [<pattern>] [<filter>]
.. note::
@ -24,15 +46,9 @@ Basic commands:
digcircle
=========
A command for easy designation of filled and hollow circles.
It has several types of options.
Shape:
:hollow: Set the circle to hollow (default)
:filled: Set the circle to filled
:#: Diameter in tiles (default = 0, does nothing)
Designate filled or hollow circles. If neither ``hollow`` nor ``filled``
is specified, the default is ``hollow``. The diameter is the number of tiles
Action:
:set: Set designation (default)

@ -1311,12 +1311,14 @@ void fInitthread(void * iodata)
// A thread function... for the interactive console.
void fIOthread(void * iodata)
{
static const char * HISTORY_FILE = "dfhack-config/dfhack.history";
IODATA * iod = ((IODATA*) iodata);
Core * core = iod->core;
PluginManager * plug_mgr = ((IODATA*) iodata)->plug_mgr;
CommandHistory main_history;
main_history.load("dfhack.history");
main_history.load(HISTORY_FILE);
Console & con = core->getConsole();
if (plug_mgr == 0)
@ -1357,7 +1359,7 @@ void fIOthread(void * iodata)
{
// a proper, non-empty command was entered
main_history.add(command);
main_history.save("dfhack.history");
main_history.save(HISTORY_FILE);
}
auto rv = core->runCommand(con, command);