* feat: add `ipProtocol` argument to `port-test` rpc method
* chore: update rpc-spec.md
* feat: split port check UI to IPv4 and IPv6 in webUI
* fix: default `open` to false if cannot get response
* chore: minor docs wording tweak
* chore: make clang-tidy happy
* chore: RPC doc tweaks
* fix: bad merge
* chore: review feedback
Co-authored-by: Charles Kerr <charles@charleskerr.com>
* chore: match quark enum with parameter case
* refactor: use descriptive strings for `ipProtocol`
* chore: update docs
* fixup! refactor: use descriptive strings for `ipProtocol`
* fixup! chore: update docs
---------
Co-authored-by: Charles Kerr <charles@charleskerr.com>
* Expose files' begin and end pieces via RPC
This adds two arguments, `beginPiece` and `endPiece`, for each of the entries
in the `files` array of the RPC's `torrent-`get` method.
The point is to allow RPC clients to display a file's completion progress as
piece-based in addition to byte-based.
* fix(gtk): prevent duplicate shortcut folders
This prevents duplicates if the recent destination is also a system
shortcut folder.
* refactor(gtk): create gtr_get_recent_dirs helper
* feat(gtk): remember 4 recent relocate dirs
* Support binding the RPC to a Unix socket on *nix
This commit adds unix socket support for a RPC. Some refactoring was
required in order to split out the RPC server's address struct from the
normal network address struct used for peers. It would cause
unacceptable overhead to add the unix socket length to the union.
Co-authored-by: Malte Voos <malte@malvo.org>
* add RPC socket mode to control unix socket perms
Unix socket permissions are important to control for security reasons,
and libevent defaults to 0755, which may not be what users want.
Co-authored-by: LaserEyess <LaserEyess@users.noreply.github.com>
Co-authored-by: Malte Voos <malte@malvo.org>
Add a getter/setter for torrent announce URLs as text that can be copied
and pasted: one URL per line, with a blank line between tiers.
C API: tr_torrentGetTrackerList() and tr_torrentSetTrackerList()
RPC APi: `trackerList` in `torrent-get` and `torrent-set`.
This deprecates `trackerAdd`, `trackerRemove`, and `trackerEdit`
from the RPC API.
* Add support for creating torrents with a source flag
* Add the source flag functionality for Mac OSX
* Source flag should be a part of the info dictionary
* Address review comments
* Rename "sourceFlag" to "source" since "Flag" is usually reserved for booleans.
* Free the "source" pointer in tr_metainfoFree.
* Add information about transmission-create argument to its manpage.
* Replace all occurences of "sourceFlag" with "source" and use "Source tag" in UI
* Settle on just "Source" in UI
* The last usage of "flag" hopefully bites the dust! ;-)
* Add a missing free for the source in tr_metainfoFree
* Add a "source" field to the torrent-get RPC method
* uncrustify
* Test for torrents having different infohashes due to different source flags.
This is the whole point of this feature, so it makes sense to test it.
* case is important
* try to incorporate the macosx xml changes
* feat: add torrent-get 'primary-mime-type' to RPC.
This is a cheap way for RPC clients to know what type of content is in a
torrent. This info can be used to display the torrent, e.g. by using an
icon that corresponds to the mime type.
* use size_t for content byte count
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* explicit boolean expressions
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* use uint64_t for content byte counts
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* avoid unnecessary logic branches
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* explicit cast
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* refactor: add an autogenerated mime-type.h header
* chore: maybe fix the win32 FTBFS
* chore: add mime-types.[ch] to xcode
* Squashed commit of the following:
commit 4c7153fa48
Author: Mike Gelfand <mikedld@users.noreply.github.com>
Date: Tue Oct 13 03:15:19 2020 +0300
Remove autotools-based build system (#1465)
* Support .git files (e.g. for worktrees, submodules)
* Fix symlinks in source tarball, switch to TXZ, adjust non-release name
* Remove autotools stuff
Co-authored-by: Mike Gelfand <mikedld@users.noreply.github.com>
* feat: add tr_stat.infoDate to note tr_info changes
The last time during this session that any tr_info field changed
(e.g. trackers/filenames edited or magnet torrent got metadata).
RPC clients can monitor this to know when to reload fields which
don't usually change.
* feat: add optional "format" arg to torrent-get RPC
If the "format" request was "objects" (default), "torrents" will be an
array of objects, each of which contains the key/value pairs matching
the request's "fields" arg. This is unchanged from previous versions.
If the format was "table", then "torrents" will be an array of arrays.
The first row holds the keys and each remaining row holds a torrent's
values for those keys. This format is more efficient in terms of JSON
generation and JSON parsing.