Commit Graph

264 Commits

Author SHA1 Message Date
Casey Rodarmor
1e5c19d02b
Add GitHub Actions workflow to build book and push to github pages
- Run book build on all commits
- Deploy site on pushes to master

type: development
2020-04-07 19:01:30 -07:00
Casey Rodarmor
b96c27e9b1
Fix build errors
- Install `musl-tools` which provides the `musl-gcc` binary, needed
   for the package script on ubuntu.
- Fix contributing file name

type: fixed
2020-04-07 19:01:30 -07:00
Casey Rodarmor
4cbeca802a
Add additional documents to release archive
- Include changelog
- Include contributing guidelines

type: distribution
2020-04-07 19:01:29 -07:00
Casey Rodarmor
5d4baa22ea
Release v0.0.3
- Bump version: `0.0.2` -> `0.0.3`
- Update changelog

type: release
2020-04-07 19:01:29 -07:00
Casey Rodarmor
86aeec3ce9
Fix release process issues
- Trigger GitHub Actions workflow on release tags
- Make build script tolerate not being called in git directory
- Omit git hash in created by message if not built in git directory
- Test created by message format

type: distribution
2020-04-07 19:01:29 -07:00
Casey Rodarmor
8b3954ff99
Release v0.0.2
- Bump version: `0.0.1` -> `0.0.2`
- Update chnagelog

type: release
2020-04-07 19:01:29 -07:00
Casey Rodarmor
498549b35c
Allow reading torrent metainfo from stdin
Torrent metainfo can be read from standard input by passing `-`:

    cat a.torrent | imdl torrent verify --input -
    cat a.torrent | imdl torrent link --input -
    cat a.torrent | imdl torrent show --input -

type: added
2020-04-07 19:01:29 -07:00
Casey Rodarmor
1c84172ad4
Skip torrent file creation with imdl torrent create --dry-run
Torrent files will not be written to disk with `--dry-run`:

    imdl torrrent create --input foo --dry-run

type: added
2020-04-07 19:01:28 -07:00
Casey Rodarmor
7e3a53ce52
Make just done default to current branch
type: development
2020-04-07 19:01:28 -07:00
Casey Rodarmor
0d7c1c0c27
Print magnet link to stdout with --link
Magnet links can be printed to standard output with:

    imdl torrent create --input PATH --link

type: added
2020-04-07 19:01:28 -07:00
Casey Rodarmor
901fa150ff
Indicate BEP 9 support in readme
type: documentation
2020-04-07 19:01:28 -07:00
Casey Rodarmor
d8055c6e6a
Allow opening magnet links after creation
Magnet links can now be opened after creation:

    imdl torrent link --open --input METAINFO

type: added
2020-04-07 19:01:28 -07:00
Casey Rodarmor
aeb9d8b317
Add name and peers to magnet links
Add additional data to magnet links in `imdl torrent link`.

- Set the `dn` query parameter with `metinfo.info.name`
- Add peers to the `x.pe` query parameter:

    imdl torrent link --peer HOST:PORT

type: added
2020-04-07 19:01:28 -07:00
Casey Rodarmor
57a358e458
Allow creating magnet links with imdl torrent link
Magnet links can now be created from a metainfo file with:

    imdl torrent link --input METAINFO

type: added
2020-04-07 19:01:27 -07:00
Casey Rodarmor
0b486cc681
Update BEP list in readme with new issue links
type: documentation
2020-04-07 19:01:27 -07:00
Casey Rodarmor
3257614c4f
Print correct and incorrect MD5 checksums in color
type: changed
2020-04-07 19:01:27 -07:00
Casey Rodarmor
1cac9ab924
Use imdl-indicatif
The `0.1.0` release is coming up, and a prerequisite to publish to
crates.io is to not depend on any non crates.io dependency.

We're using the `{binary_bytes_per_sec}` formatting spec, which is only
in my fork.

I published my fork to crates.io as `imdl-indicatif`, and this diff
starts depending on that fork.

type: distribution
2020-04-07 19:01:27 -07:00
Casey Rodarmor
0033e8381f
Test imdl torrent verify output
- Test all individual `FileError` variants
- Test terminal colors
- Test multiple and single file torrents

type: testing
2020-04-07 19:01:27 -07:00
Casey Rodarmor
2ea5e0b384
Deny clippy::too_many_arguments
type: development
2020-04-07 19:01:26 -07:00
Casey Rodarmor
1532113782
Print individual file torrent verification errors
If torrent verification fails, print all errors with individual files.

type: changed
2020-04-07 19:01:26 -07:00
Casey Rodarmor
f8e3fd594b
Add explanation paragraph to readme
type: documentation
2020-04-07 19:01:26 -07:00
Casey Rodarmor
f1cc12858c
Use bendy dep from crates.io instead of GitHub
type: distribution
2020-04-07 19:01:26 -07:00
Casey Rodarmor
1daa18ef9a
Add progress messages and bar to imdl torrent verify
type: added
2020-04-07 19:01:26 -07:00
Casey Rodarmor
5a0bd2dda7
Add braille spinner char explanation and legend
type: documentation
2020-04-07 19:01:25 -07:00
Casey Rodarmor
2edf8a4fab
Style imdl torrent create progress messages
type: changed
2020-04-07 19:01:25 -07:00
Casey Rodarmor
8c0d918607
Use concat!(...) to format braille tick chars
type: reform
2020-04-07 19:01:22 -07:00
Casey Rodarmor
c3879db06f
Remove matches macro
type: reform
2020-04-07 19:01:16 -07:00
Casey Rodarmor
bb34936c2f
Only write spinner and progress bar when connected to terminal
type: fixed
2020-04-07 19:01:16 -07:00
Casey Rodarmor
2cfdad2597
Fail early if destination .torrent file exists
Check if torrent file to create exists and fail early.

type: changed
2020-04-07 19:01:16 -07:00
Casey Rodarmor
4371bb1402
Improve spinner and progress bar
- Switch to my branch of indicatif on github
- Use binary braille spinner
- Use fine-grained progress bar
- Improve template formatting
- Use SI units for bytes/s

type: changed
2020-04-07 19:01:16 -07:00
Casey Rodarmor
b25b389ae6
Rename Target to OutputTarget
Making it specific to output allows us to be more specific in the
display message, and possibly add output-specific code in the future.

type: reform
2020-04-07 19:01:16 -07:00
Casey Rodarmor
0de2b1719e
Only show torrent summary on create with --show
The torrent summary is large, and makes it easy to miss the create
progress bar and messages. Only show summary if the user passes
`--show` / `-S` to `imdl torrent create`.

type: changed
2020-04-07 19:01:16 -07:00
Casey Rodarmor
06947fd63e
Make table names more greppable
- Use lowercase table names when priting to terminal
- Use `Creation Date` instead of `Created`, to make it
  distinct from the `Created` field

type: changed
2020-04-07 19:01:15 -07:00
RJ Rybarczyk
bdaec27caf
Add piece hashing progress bar
type: added
2020-04-07 19:01:15 -07:00
RJ Rybarczyk
c6cd78f565
Add progress messages to imdl torrent create
- Add messages showing overall progress
- Add file search spinner

type: added
2020-04-07 19:01:15 -07:00
Casey Rodarmor
2415d88d92
Add empty book
The book should eventually contain all documentation that isn't suitable
for the readme or help text.

For now it's empty, but it seemed useful to add the scaffolding, so
adding to it is low friction.

type: documentation
2020-04-07 19:01:15 -07:00
Casey Rodarmor
21a87a46f3
Improve imdl torrent create flags
Add short flags and make some long flags shorter.

type: added
2020-04-07 19:01:15 -07:00
Casey Rodarmor
3276f2d043
Add short flags to imdl torrent {show,verify}
type: added
2020-04-07 19:01:15 -07:00
Casey Rodarmor
027b229df1
Test piece-hashing edge cases
- Uneven last piece
- Even last piece
- Piece that spans multiple files
- Multiple pieces in one file

type: testing
2020-04-07 19:01:14 -07:00
Casey Rodarmor
2b19a62134
Test creating torrents from . and ..
Test that torrent gets actual name of directory, and is created in the
correct location.

type: testing
2020-04-07 19:01:14 -07:00
Casey Rodarmor
fa6d4e6ad0
Revise command line value names
Make command line value names make sense in context. For example,
`--announce URL` instead of `--announce ANNOUNCE`.

type: documentation
2020-04-07 19:01:14 -07:00
Casey Rodarmor
cba238470d
Remove long_help in favor of help
Maintaining two help strings in order to have a shorter help message
doesn't seem worth it.

type: documentation
2020-04-07 19:01:14 -07:00
Casey Rodarmor
4fffa777b4
Refactor Opt into Arguments, Options, and Subcommand
type: reform
2020-04-07 19:01:14 -07:00
RJ Rybarczyk
eb8efaf528
Fix hidden method unused arg warning
type: fixed
2020-04-07 19:01:13 -07:00
Casey Rodarmor
1c22623df4
Trigger GitHub actions build on either push and PR to master
type: development
2020-04-07 19:01:13 -07:00
Casey Rodarmor
f2a5f13729
Format with unstable rustfmt options
- Format with nightly rustfmt
- Enable unstable options in rustfmt.toml
- Turn off git text file detection, so newlines are always unix newlines

type: reform
2020-04-07 19:01:07 -07:00
Casey Rodarmor
d71bdffda1
Refactor tests and improve verification
Improve verification somewhat, but mostly refactor tests
to use test tree, and be nicer to read and write.

type: changed
2020-04-07 19:01:07 -07:00
Casey Rodarmor
2fb5bdb933
Test that metainfo bencode representation is correct
Check that metadata is serialized to expected bencode representation.

type: testing
2020-04-07 19:01:06 -07:00
Casey Rodarmor
fdb18bb8d8
Update discord invite link
type: documentation
2020-04-07 19:01:06 -07:00
Casey Rodarmor
55f2fcc738
Add discord badge to readme
type: documentation
2020-04-07 19:01:06 -07:00