TweetSVG
- - ++ TweetSVG + +
+ ++ Generate an SVG for a given Tweet ID ++ +
+ Enter the URL or ID of a tweet to have an SVG generated for it, no JavaScript required! +
- - +diff --git a/Dockerfile b/Dockerfile index afeedca..c74e6f5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:alpine AS builder +FROM golang:1.16-alpine AS builder RUN apk update && apk add --no-cache git && apk add -U --no-cache ca-certificates WORKDIR /app/ ADD go.mod go.sum ./ @@ -7,10 +7,7 @@ ADD . . RUN GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -ldflags="-w -s" -o tweetsvg main.go FROM scratch - WORKDIR /app/ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ COPY --from=builder /app/tweetsvg /app/tweetsvg -ADD tweet.svg.tmpl index.html ./ - ENTRYPOINT ["/app/tweetsvg"] diff --git a/README.md b/README.md index c7691a9..55b46b0 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,13 @@ + + # TweetSVG Generate an SVG for a given Tweet ID diff --git a/go.mod b/go.mod index 11adc62..89259d7 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module tweetsvg -go 1.15 +go 1.16 require ( github.com/ChimeraCoder/anaconda v2.0.0+incompatible @@ -9,7 +9,7 @@ require ( github.com/dustin/go-jsonpointer v0.0.0-20160814072949-ba0abeacc3dc // indirect github.com/dustin/gojson v0.0.0-20160307161227-2e71ec9dd5ad // indirect github.com/garyburd/go-oauth v0.0.0-20180319155456-bca2e7f09a17 // indirect - github.com/grokify/html-strip-tags-go v0.0.1 // indirect + github.com/grokify/html-strip-tags-go v0.0.1 github.com/joho/godotenv v1.3.0 golang.org/x/net v0.0.0-20210119194325-5f4716e94777 // indirect ) diff --git a/index.html b/index.html index 781fb83..8d9c1e1 100644 --- a/index.html +++ b/index.html @@ -3,75 +3,94 @@
++ Generate an SVG for a given Tweet ID ++ +
+ Enter the URL or ID of a tweet to have an SVG generated for it, no JavaScript required! +
- - +