- Replace `ioutil.TempFile` with `os.CreateTemp` in `TestEmptyDirectory` test function
- Remove unused import `io/ioutil` in `serve_test.go`
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Rename `index.html` and `example.go` within the `example/embed/data/server` and `example/embed` directories to be under a new `_example` directory.
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Add documentation for serving local files and embedded folders in README.md
- Add new example code for serving embedded folders in Go
- Create new `embed_folder.go` file with functions to serve embedded folders
- Create new `embed_folder_test.go` file with tests for serving embedded folders
- Add HTML template files for embedded server example
- Rename `static.go` to `local_file.go` and remove unused code
- Create new `local_file_test.go` file with tests for serving local files
- Create new `serve.go` file with middleware handler for serving static files
- Rename `static_test.go` to `serve_test.go` and refactor test functions
- Remove redundant test case `TestListIndex` from `serve_test.go`
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Update Go version requirement from `1.15` to `1.18`
- Upgrade `github.com/gin-gonic/gin` dependency from `v1.8.1` to `v1.9.1`
- Upgrade `github.com/stretchr/testify` dependency from `v1.8.0` to `v1.8.4`
- Add multiple new indirect dependencies including `github.com/bytedance/sonic`, `github.com/chenzhuoyu/base64x`, and others
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Standardize cron syntax to use double quotes in codeql.yml
- Update CodeQL action to version 3 in codeql.yml
- Standardize Go version syntax to use double quotes in go.yml
- Update golangci-lint-action to version 4 in go.yml
- Update actions/cache to version 4 in go.yml
- Update codecov-action to version 4 in go.yml
- Standardize wildcard syntax to use double quotes in goreleaser.yml
- Remove unnecessary newlines in goreleaser.yml
- Update Go version to use semver range in goreleaser.yml
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/codeql.yml`
- Update the version of `actions/setup-go` from v3 to v5 in `.github/workflows/go.yml`
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/go.yml`
- Update the version of `actions/setup-go` from v3 to v5 in `.github/workflows/go.yml`
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/goreleaser.yml`
- Update the version of `actions/setup-go` from v2 to v5 in `.github/workflows/goreleaser.yml`
- Update the version of `goreleaser/goreleaser-action` from v3 to v5 in `.github/workflows/goreleaser.yml`
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Update Go version requirement from `1.15` to `1.18`
- Upgrade `github.com/gin-gonic/gin` dependency from `v1.8.1` to `v1.9.1`
- Upgrade `github.com/stretchr/testify` dependency from `v1.8.0` to `v1.8.4`
- Add multiple new indirect dependencies including `github.com/bytedance/sonic`, `github.com/chenzhuoyu/base64x`, and others
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Standardize cron syntax to use double quotes in codeql.yml
- Update CodeQL action to version 3 in codeql.yml
- Standardize Go version syntax to use double quotes in go.yml
- Update golangci-lint-action to version 4 in go.yml
- Update actions/cache to version 4 in go.yml
- Update codecov-action to version 4 in go.yml
- Standardize wildcard syntax to use double quotes in goreleaser.yml
- Remove unnecessary newlines in goreleaser.yml
- Update Go version to use semver range in goreleaser.yml
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/codeql.yml`
- Update the version of `actions/setup-go` from v3 to v5 in `.github/workflows/go.yml`
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/go.yml`
- Update the version of `actions/setup-go` from v3 to v5 in `.github/workflows/go.yml`
- Update the version of `actions/checkout` from v3 to v4 in `.github/workflows/goreleaser.yml`
- Update the version of `actions/setup-go` from v2 to v5 in `.github/workflows/goreleaser.yml`
- Update the version of `goreleaser/goreleaser-action` from v3 to v5 in `.github/workflows/goreleaser.yml`
Signed-off-by: Bo-Yi Wu <appleboy.tw@gmail.com>