Age | Commit message (Collapse) | Author |
|
|
|
|
|
Changed Url to URL
Adjusted spacing
Dropped superflous colons
Old style:
wgetpaste -S
Services supported: (case sensitive):
Name: | Url:
==========|=================
0x0 | http://0x0.st
New style:
wgetpaste -S
Services supported: (case sensitive):
Name | URL
==========|=================
0x0 | http://0x0.st
|
|
Previous pattern: https://gist.github.com/raw/<organization_label>/<gist_id> is now http 404
New pattern looks to be: https://gist.github.com/<organization_label>/<gist_id>/raw which is http 200
|
|
Signed-off-by: Richard Rogalski <rrogalski@firemail.cc>
Closes: #19
|
|
|
|
Don't strip ANSI codes.
|
|
Read config files before parsing CLI args. Allows all options to be set
via config and overridden on the CLI.
|
|
Specified in the code with `pgz` and in the cli for usage and brevity.
|
|
Sprunge seems to have recently died. Disable it by removing it from the
service list, but keep the core bits in case it decides to come back.
RIP ;(
|
|
Avoids a warning about Node.js 12 actions being deprecated.
|
|
- Run actions on PR's as well as pushes
- Bump run-test-ansi to `ubuntu-latest` (which is 22.04 at the time of
writing)
|
|
Signed-off-by: Sam James <sam@gentoo.org>
|
|
Signed-off-by: Sam James <sam@gentoo.org>
|
|
Signed-off-by: Sam James <sam@gentoo.org>
|
|
Signed-off-by: Sam James <sam@gentoo.org>
|
|
|
|
Found by codespell.
|
|
|
|
Strip ANSI codes using app-text/ansifilter
Closes: #34
|
|
dpaste intermittently fails DNSSEC authentication which causes it to be
inaccessible for people who have DNSSEC enabled. Other services do not seem to have this
issue, and bpaste seems to be a reasonable default.
|
|
Also for wgetpaste.spec this time ;-).
|
|
Closes #27.
|
|
Convert from array to map, service -> reason. Printing the reason as
part of the hard skip message makes the output self-documenting.
|
|
|
|
AUTH_SKIPS is a list of services for which an HTTP 401 is an expected
response if an auth token isn't given. 401 for a service outside of the
list means a changed/broken API.
Invert the `if ! diff then fail else success` for readability.
|
|
DL_DIR/* tries to diff error logs with the test data if they exist.
|
|
|
|
Automatically runs test/test.sh when code is pushed to the repo.
|
|
Slightly different behavior based on if it's a hard skip, auth skip, or
post/download failure skip. HARD_SKIPS array to control which services
are always skipped. Add total skips and fail logs to summary.
|
|
|
|
Posts test/test.txt onto any pastebins it can. Downloads the resulting
pate into a temp dir as /tmp/wgetpaste_test.XXXXX/<service>.txt. Runs
diff(1) (ignoring trailing whitespace) to compare the download with the
test data.
|
|
'echo -e' is used to prepare data for dpaste. However if
`echo -e "${content}"` is used, the content gets interpreted as well.
This results in constructs such as '\0' getting misinterpreted as the
byte 0x00. As a result, the interperted context can result in output
not compatible with dpaste.
fixes bug #25
|
|
|
|
|
|
|
|
|
|
escape_description_dpaste() and escape_input_dpaste() are missing which
causes the default escape function to be used. This results in mangled
pastes.
Fixes: #22
|
|
Service owner states in https://github.com/rupa/sprunge/issues/46 that
the size limit for both ix.io and sprunge.us is "roughly a meg". As
"meg" appears to mean 1 MiB, the size is set at 1 million bytes (1 MB).
|
|
|
|
|
|
Updates the code to use the new dpaste API and corrects the max
dpaste size limit value.
|
|
Service owner states in https://github.com/rupa/sprunge/issues/46 that
the size limit for both ix.io and sprunge.us is "roughly a meg". As
"meg" appears to mean 1 MiB, the size is set at 1 million bytes (1 MB).
|
|
As previously implemented REGEX_RAW_ix_io would cause the URL to
be printed twice. This change corrects that error.
|
|
|
|
The current post handling logic assumes that either POST_${engine} is
defined and is a string, or json_${engine} is defined and is a function.
This logic does not work for paste bins such as ix.io.
To make the logic more flexible, the string-function hybrid approach has
been replaced with a function call chain. The entry-point to this
chain is always
POST_${engine} NICK DESCRIPTION LANGUAGE EXPIRATION CVT_TABS INPUT
and for most services POST_${engine} is defined as:
POST_generic <post format string> $1 $2 $3 $4 $5 $6
where POST_generic is the original logic for handling post requests.
For JSON post submissions, the coresponding json_${engine} function is
renamed to POST_${engine} and the arguments adjusted to match the
calling convention mentioned above.
|
|
|
|
|
|
|
|
|