| Age | Commit message (Collapse) | Author |
|
[CHORE]
Update README for broken link in example.
While at it, break the links that point to localhost and email.
[CHORE]
Run eslint from node_modules/.bin directory directly.
Using npx does not guarantee works on system installed nodejs.
[CHORE]
go.mod: set minimum Go version to 1.24.0 and update all dependencies.
|
|
|
|
Using npx does not guarantee works on system installed nodejs.
|
|
While at it, break the links that point to localhost and email.
|
|
[BREAKING CHANGES]
The git submodule in "_www/wui" has been renamed to "_www/pakakeh_ts".
If you have cloned this project before, you need to rename the sub directory
manually and re-init it.
----
$ mv _www/wui _www/pakakeh_ts
$ git submodule update --init
----
[CHORE]
The linter has been replaced many times, from revive to "go vet", and from
using binary form of fieldalignment and shadow; to use internal command
gocheck that do the same things, which simplify our setup.
[CHORE]
Split the CSS into separate file.
This is allow modifying the CSS without touching the index.html, and may be
used by other HTML files later.
[CHORE]
Fix some broken links in the documentation pages, including link to
Changelog, README, and SPEC.
|
|
The previous Development section now become Links section.
|
|
The idea is to allow developer who browse the repository to see the file
immediately.
The one in the doc/ directory now contains the symlink.
|
|
The fieldalignment and shadow is linter from golang.org/x/tools.
This linters actually have an API that can be combined into a program,
which provided by package "pakakeh.go/lib/goanalysis".
|
|
|
|
The previous port, 10007, is used for local deployment in my home PC.
When we run the test it may cause port conflicts with it.
|
|
|
|
Instead of inside the index.html split the CSS so we can modify them
without touching the HTML.
|
|
|
|
|
|
|
|
|
|
The flag "dev" is boolean that when set will run service in development
mode, watching the adoc and ts files.
The flag "http" is string that set the HTTP listen address.
|
|
|
|
|
|
This include updating the git submodule on pakakeh.ts.
|
|
=== Breaking changes
* all: refactoring form input for multipart form-data
This changes replace handling type for storing multipart form-data
from "map[string][]byte" to [*multipart.Form] based on changes on
module "pakakeh.go".
=== Enhancements
* all: make HTTP Target Params works along with WithRawBody
Previously, if WithRawBody is true, the Params will not be rendered
and parsed during Run. This changes makes the Params works along with
WithRawBody. If Params are set it will be rendered along with text area
for raw body.
* _www: support HTTP target with content type "text/html"
In the Target form, user can select to send body as "text/html".
* all: add git.sr.ht APIs into example
The APIs is created using https://man.sr.ht/git.sr.ht/api.md as
reference. We also needs the API to create webhook since no other way
to create it in current sourcehut web.
=== Bug fixes
* _www: fix save on null Headers and Vars
If the user does not define the Headers, clicking Run on any HTTP
Target will result in error when "save" function executed before it.
* _www: fix form input type file where content is binary
If the file in FormInput is binary, the conversion to
"FormInput.value" will fail with an error like "invalid characters in
String".
* all: use [route.Path] to generate parameters
Using [route.String] does not works if the parameter can be empty,
while [route.Path] replace all keys and return the path as is.
=== Chores
* all: add task to initialize the repository and tools
The task "init" include initializing git submodule, installing third
party tools for linters, and installing node packages.
|
|
Using ".reuse/dep5" has been deprecated since REUSE v3.2.
While at it, add missing license to some files in testdata.
|
|
|
|
This is so we can build again if its failed, after lint and test has
passed.
|
|
The wui repository has been renamed to pakakeh.ts.
|
|
|
|
The APIs is created using https://man.sr.ht/git.sr.ht/api.md as
reference.
We also needs the API to create webhook since no other way to create it
in current sourcehut web.
|
|
|
|
Using [route.String] does not works if the parameter can be empty,
while [route.Path] replace all keys and return the path as is.
|
|
Previously, if WithRawBody is true, the Params will not be rendered
and parsed during Run.
This changes makes them Params works along with WithRawBody.
If Params are set it will be rendered along with text area for raw body.
|
|
|
|
This changes replace handling type for storing multipart form-data from
"map[string][]byte" to [*multipart.Form] based on changes on module
"pakakeh.go".
|
|
If the file in FormInput is binary, the conversion to "FormInput.value"
will fail with an error like "invalid characters in String".
|
|
The task "init" include initializing git submodule, installing third
party tools for linters, and installing node packages.
|
|
|
|
If the user does not define the Headers, clicking Run ony any HTTP
Target will result in error when "save" function executed before it.
|
|
This release replace "share" module with "pakakeh.go".
The "share" module repository has been moved to SourceHut with new name
"pakakeh.go". For more information about the changes see pakakeh.go
project at https://sr.ht/~shulhan/pakakeh.go.
|
|
On the "lib/http" we refactoring RequestMethod and RequestType type
from int to string for readability, when the value is encoded, for
example to JSON.
So instead of 0, 1 or 2; it will print "GET", "CONNECT", or "HEAD".
|
|
|
|
|
|
=== Breaking changes
* target: changes Opts to non-pointer
Previously, we use pointer to indicated that the Target can be
attacked or not. Since HTTPTarget now have AllowAttack, this options
can be changes to non-pointer.
* all: change the signature of default request/response dumper
Instead of function that use the signature of HTTPRequestDumper/
HTTPResponseDumper; change it to function that return HTTPRequestDumper/
HTTPResponseDumper. In this way, the documentation can show the clear
relation between function and its type.
=== New features
* all: add global HTTP headers for Target
The Headers field on Target define the global headers that will be
send along with all HTTPTarget or WebSocketTarget. The same header can
also be defined on HTTPTarget that override the value of Target.
* all: add default HTTPRunHandler
Previously, the default HTTPRunHandler is hidden, called dynamically
based on Run is nil or not. This changes make it exported as function
that return HTTPRunHandler to show how define and create a custom
HTTPRunHandler.
* all: add default HTTPParamsConverter for [HTTPTarget.ParamsConverter]
The DefaultParamsConverter define default function to convert
[HTTPTarget.Params] to its equivalent parameters in HTTP, either as
query in URL or as bytes in body.
This changes introduce breaking changes in HTTPTarget where field
ConvertParams renamed to ParamsConverter.
* all: set default HTTPTarget Attack if its not set
Previously, the function for Attack need to be coded manually.
This changes introduce new function DefaultHTTPAttack that generate
HTTPAttackHandler based on the HTTPTarget method, request type, and
Params; if AllowAttack is true and Attack is nil.
=== Bug fixes
* all: fix null navigation links
If the navLinks fields is empty, the HTTP API will return "null" and
cause the rendering error. This changes fix this issue by allocating
the slice navLinks with one capabilities to make JSON always return
"[]" if its empty.
|
|
|
|
|
|
This will allow running Example server with "make dev" and the test with
"make" or "make test" at the same time.
|
|
The Headers field on Target define the global headers that will be send
along with all HTTPTarget or WebSocketTarget.
The same header can also be defined on HTTPTarget that override the
value of Target.
|
|
If the navLinks fields is empty, the HTTP API will return "null" and make
the rendering error.
This changes fix this issue by allocating the slice navLinks with one
capabilities to make JSON always return "[]" if its empty.
|
|
The Run handler is handled automatically.
|
|
In some cases we found that if the HTTP response code is 202 the JSON
response body is not indented.
Turns out this is caused by HTTP Content-Type in response is
"text/plain".
Closes: https://todo.sr.ht/~shulhan/gorankusu/6
|
|
Previously, the default HTTPRunHandler is hidden, called dynamically
based on Run is nil or not.
This changes make it exported as function that return HTTPRunHandler
to show how define and create a custom HTTPRunHandler.
|
|
Previously, we use pointer to indicated that the Target can be attacked
or not.
Since HTTPTarget now have AllowAttack, this options can be changes to
non-pointer.
|