introduce release pipeline with taskfile and goreleaser
@ -11,12 +11,14 @@ builds:
|
|||||||
- CGO_ENABLED=0
|
- CGO_ENABLED=0
|
||||||
goos:
|
goos:
|
||||||
- linux
|
- linux
|
||||||
|
- windows
|
||||||
- darwin
|
- darwin
|
||||||
- openbsd
|
- openbsd
|
||||||
archives:
|
archives:
|
||||||
- replacements:
|
- replacements:
|
||||||
darwin: Darwin
|
darwin: Darwin
|
||||||
linux: Linux
|
linux: Linux
|
||||||
|
windows: Windows
|
||||||
openbsd: OpenBSD
|
openbsd: OpenBSD
|
||||||
386: i386
|
386: i386
|
||||||
amd64: x86_64
|
amd64: x86_64
|
||||||
@ -73,7 +75,7 @@ brews:
|
|||||||
|
|
||||||
# Your app's description.
|
# Your app's description.
|
||||||
# Default is empty.
|
# Default is empty.
|
||||||
description: "serra - I wrote a typing trainer to get into my ortholinear keyboard"
|
description: "serra - Personal Magic: The Gathering Collection Tracker "
|
||||||
|
|
||||||
# SPDX identifier of your app's license.
|
# SPDX identifier of your app's license.
|
||||||
# Default is empty.
|
# Default is empty.
|
||||||
|
|||||||
@ -12,6 +12,14 @@ tasks:
|
|||||||
generates:
|
generates:
|
||||||
- "./serra"
|
- "./serra"
|
||||||
|
|
||||||
|
release:
|
||||||
|
interactive: true
|
||||||
|
cmds:
|
||||||
|
- git tag | tail -5
|
||||||
|
- read -p "Version v1.1.1 " version ; git tag $version
|
||||||
|
- git push --tags
|
||||||
|
- goreleaser release --rm-dist
|
||||||
|
|
||||||
default:
|
default:
|
||||||
cmds:
|
cmds:
|
||||||
- task: build
|
- task: build
|
||||||
|
|||||||
BIN
imgs/add.png
|
Before Width: | Height: | Size: 11 KiB After Width: | Height: | Size: 12 KiB |
BIN
imgs/cards.png
|
Before Width: | Height: | Size: 89 KiB After Width: | Height: | Size: 104 KiB |
BIN
imgs/flops.png
Normal file
|
After Width: | Height: | Size: 212 KiB |
BIN
imgs/set.png
|
Before Width: | Height: | Size: 122 KiB After Width: | Height: | Size: 91 KiB |
BIN
imgs/sets.png
|
Before Width: | Height: | Size: 100 KiB After Width: | Height: | Size: 83 KiB |
BIN
imgs/stats.png
|
Before Width: | Height: | Size: 43 KiB After Width: | Height: | Size: 125 KiB |
BIN
imgs/tops.png
|
Before Width: | Height: | Size: 208 KiB After Width: | Height: | Size: 217 KiB |
BIN
imgs/update.png
Normal file
|
After Width: | Height: | Size: 108 KiB |
18
readme.md
@ -88,16 +88,24 @@ Calculate some stats for all of your cards
|
|||||||
|
|
||||||
## Tops
|
## Tops
|
||||||
|
|
||||||
Show what cards/se gained most value
|
Show what cards/set gained most value
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
## Flops
|
||||||
|
|
||||||
|
Show what cards/set lost most value
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
## Update
|
## Update
|
||||||
|
|
||||||
The update mechanism iterates over each card in your collection and fetches
|
The update mechanism iterates over each card in your collection and fetches
|
||||||
its price. After all cards you own in a set are updated, the set value will
|
its price. After all cards you own in a set are updated, the set value will
|
||||||
update. After all Sets are updated, the whole collection value is updated.
|
update. After all Sets are updated, the whole collection value is updated.
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
## Adding all those cards, manually?
|
## Adding all those cards, manually?
|
||||||
|
|
||||||
Yes. While there are serveral OCR/Photo Scanners for mtg cards, I found they
|
Yes. While there are serveral OCR/Photo Scanners for mtg cards, I found they
|
||||||
@ -121,12 +129,14 @@ read> 18
|
|||||||
Its basically typing 2-3 digit numbers and hitting enter. I was way faster
|
Its basically typing 2-3 digit numbers and hitting enter. I was way faster
|
||||||
with this approach then Smartphone scanners.
|
with this approach then Smartphone scanners.
|
||||||
|
|
||||||
# Install
|
# Development
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
go build .
|
go build .
|
||||||
./serra
|
./serra
|
||||||
|
|
||||||
# Cheatsheet Queries
|
## Cheatsheet Queries
|
||||||
|
|
||||||
Find cards that increased prices
|
Find cards that increased prices
|
||||||
|
|
||||||
@ -155,7 +165,7 @@ Calculate what cards gained most value in percent
|
|||||||
|
|
||||||
db.cards.aggregate({$project: {set: 1, collectornumber:1, name: 1, "old": {$arrayElemAt: ["$serra_prices.value", -2]}, "current": {$arrayElemAt: ["$serra_prices.value", -1]} }}, {$match: {old: {$gt: 2}}} ,{$project: {name: 1,set:1,collectornumber:1,current:1, "rate": {$subtract: [{$divide: ["$current", {$divide: ["$old", 100]}]}, 100]} }}, {$sort: { rate: -1}})
|
db.cards.aggregate({$project: {set: 1, collectornumber:1, name: 1, "old": {$arrayElemAt: ["$serra_prices.value", -2]}, "current": {$arrayElemAt: ["$serra_prices.value", -1]} }}, {$match: {old: {$gt: 2}}} ,{$project: {name: 1,set:1,collectornumber:1,current:1, "rate": {$subtract: [{$divide: ["$current", {$divide: ["$old", 100]}]}, 100]} }}, {$sort: { rate: -1}})
|
||||||
|
|
||||||
# MongoDB Operations
|
## MongoDB Operations
|
||||||
|
|
||||||
A few commands that do backups and exports of your data inside of the docker
|
A few commands that do backups and exports of your data inside of the docker
|
||||||
container.
|
container.
|
||||||
|
|||||||