Revision 413a52d0eed8582e4c1511e210d7e3f36fe2fe3a authored by Jorropo on 14 December 2023, 14:31:42 UTC, committed by GitHub on 14 December 2023, 14:31:42 UTC
Release: v0.25.0 [skip changelog]
gen_main.sh
#!/usr/bin/env bash
dir=${1:?first parameter with dir to work in is required}
pkg=${2:?second parameter with full name of the package is required}
main_pkg="$dir/main"
shortpkg="uniquepkgname"
mkdir -p "$main_pkg"
cat > "$main_pkg/main.go" <<EOL
package main
import (
$shortpkg "$pkg"
)
var Plugins = $shortpkg.Plugins //nolint
func main() {
panic("this is a plugin, build it as a plugin, this is here as for go#20312")
}
EOL
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...