Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
101 commits
Select commit Hold shift + click to select a range
2ca5e1a
Initialized with Ignite CLI
Dec 16, 2024
e8b319d
Initialized with Ignite CLI
Dec 16, 2024
556342c
Initialized with Ignite CLI
Dec 16, 2024
6d279e2
Initialized with Ignite CLI
Dec 16, 2024
589d6a9
feat(#242): Added base
lxgr-linux Dec 16, 2024
884412c
feat(#242): Small voting commit
lxgr-linux Dec 16, 2024
66852ee
feat(#242): First generated txs
lxgr-linux Dec 16, 2024
6ec4e28
Initialized with Ignite CLI
Dec 16, 2024
e6a1612
feat(#242): First generated txs
lxgr-linux Dec 16, 2024
eb48e8d
feat(#242): matches
lxgr-linux Dec 16, 2024
44184b8
feat(#242): Second wave of txs
lxgr-linux Dec 16, 2024
2597210
feat(#242): Small type fixes
lxgr-linux Dec 16, 2024
a556ecd
feat(#242): next wave of transactions
lxgr-linux Dec 16, 2024
7d1780e
feat(#242): Card proto
lxgr-linux Dec 16, 2024
1cc00e8
feat(#242): Next wave
lxgr-linux Dec 16, 2024
96c1078
feat(#242): Match confirm
lxgr-linux Dec 16, 2024
0a0a4ef
feat(#242): Updated gen.sh
lxgr-linux Dec 16, 2024
8681cb6
feat(#242): Next wave
lxgr-linux Dec 16, 2024
c8e33f9
feat(#242): Scaffolded last messages
lxgr-linux Dec 17, 2024
45f5ccf
feat(#242): Added generic type keeper
lxgr-linux Dec 17, 2024
a19e9be
feat(#242): Added keepers
lxgr-linux Dec 17, 2024
e90941b
feat(#242): Added bankkeeper
lxgr-linux Dec 17, 2024
aa9b778
feat(#242): Added feature flags
lxgr-linux Dec 17, 2024
b6ad90d
feat(#242): CardArtworkAdd
lxgr-linux Dec 17, 2024
dd418fb
feat(#242): SetArtworkAdd
lxgr-linux Dec 17, 2024
b44f18a
feat(#242): SetCardAdd
lxgr-linux Dec 17, 2024
fa20805
feat(#242): SetContributorAdd
lxgr-linux Dec 17, 2024
2e284bc
feat(#242): SetStoryAdd
lxgr-linux Dec 17, 2024
9d1a3df
feat(#242): Added reporter apoint and rebuild gtk
lxgr-linux Dec 19, 2024
c25b02d
feat(#242): move method to type
lxgr-linux Dec 19, 2024
a787b78
feat(#242): Many things
lxgr-linux Dec 19, 2024
06b6fc0
feat(#242): All msgs should be implemented now
lxgr-linux Dec 23, 2024
c5c5464
feat(#242): Rewrote some gtk stuff
lxgr-linux Dec 26, 2024
ee9f54d
fix(#242): Small keyrenames so chain actually starts again
lxgr-linux Feb 16, 2025
0cd02ea
feat(#242): Added card query proto
lxgr-linux Feb 16, 2025
d3b17a6
feat(#242): Added user query proto
lxgr-linux Feb 16, 2025
4e8a863
feat(#242): renamed status to cardStatus because hell
lxgr-linux Feb 16, 2025
48f0d97
feat(#242): im in pain
lxgr-linux Feb 16, 2025
906eea9
feat(#242): renamed keepers because of name conflics with generated q…
lxgr-linux Feb 16, 2025
b460616
feat(#242); Cards fr
lxgr-linux Feb 16, 2025
d8f3b80
feat(#242): SetWithAtwork
lxgr-linux Feb 16, 2025
9f18b8a
feat(#242): Added set and match query proto
lxgr-linux Feb 16, 2025
f811431
feat(#242): Added council and sellOffer query proto
lxgr-linux Feb 16, 2025
49a9723
feat(#242): changed ids to uints
lxgr-linux Feb 16, 2025
0bbb9f2
feat(#242): Added server query and added editorconfig
lxgr-linux Feb 16, 2025
11c6346
feat(#242): Added encounter query
lxgr-linux Feb 16, 2025
392a303
feat(#242): Added encounter queries proto
lxgr-linux Feb 16, 2025
57bc424
feat(#242): cosmos v0.50.11
lxgr-linux Feb 16, 2025
bf5fa23
feat(#242): Added CardchainInfo query proto
lxgr-linux Feb 16, 2025
1d1c98b
feat(#242): Added small bullshit queries proto
lxgr-linux Feb 16, 2025
6ad6443
fix(#242): Ignite is utter garbage
lxgr-linux Feb 16, 2025
e95117c
feat(#242): Added Matches Query proto
lxgr-linux Feb 16, 2025
72137a2
feat(#242): Added Sets Query
lxgr-linux Feb 16, 2025
34fac64
feat(#242): Added CardContent protos
lxgr-linux Feb 16, 2025
03f6fa7
feat(#242): Added Card queries
lxgr-linux Feb 16, 2025
c84b99c
feat(#242): Added cards query
lxgr-linux Feb 16, 2025
22500b7
feat(#242): Added match queries
lxgr-linux Feb 16, 2025
7240f75
feat(#242): Added selloffers Query
lxgr-linux Feb 16, 2025
8326093
feat(#242): Added last queries, so i hope
lxgr-linux Feb 16, 2025
11ec505
feat(#242): Removed product details, because
lxgr-linux Feb 17, 2025
e00949a
fix: encounter list validation
lxgr-linux Feb 17, 2025
daedaf1
feat: renamed stuff because yes
lxgr-linux Feb 17, 2025
80cae9d
feat(#242): Added genesis and params
lxgr-linux Feb 17, 2025
528c467
feat(#242): Added Endblocker
lxgr-linux Feb 17, 2025
bc13fa7
feat(#242): Updated gitignore
lxgr-linux Feb 18, 2025
6bec769
feat(#242): Added banCard
lxgr-linux Feb 18, 2025
08b1f15
feat(#242): Renamed banCard to CardBan
lxgr-linux Feb 18, 2025
b826549
feat(#242): Added EarlyAccessGrant
lxgr-linux Feb 18, 2025
67a087e
feat(#242): Apointing Matchreporter is now a proposal
lxgr-linux Feb 18, 2025
1f5b0ad
feat(#242): Added SetActivate
lxgr-linux Feb 18, 2025
502bdcb
feat(#242): Added CardCopyrightClaim
lxgr-linux Feb 18, 2025
41907f8
feat(#242): Added ff queries
lxgr-linux Feb 18, 2025
6db94c3
feat(#242): Added ff proposal
lxgr-linux Feb 18, 2025
f03e458
fix: Added name to encounters, yes
lxgr-linux Feb 18, 2025
dc29b9a
fix: Maybe fixed encouter picture
lxgr-linux Feb 18, 2025
13a4420
feat: Fixed genesis imort
lxgr-linux Feb 20, 2025
b93dafb
fix: QueryCards
lxgr-linux Feb 21, 2025
4b15597
feat(#247): Made encounters override
lxgr-linux Feb 21, 2025
05d97f3
fix(#245): Updated ecnounter drawlist length
lxgr-linux Feb 21, 2025
ea67a65
feat(#247): Formating
lxgr-linux Feb 21, 2025
9f6ba57
update peer nodes, cc node
patrickwieth Jul 1, 2025
3d85d97
new docker build
patrickwieth Jul 7, 2025
746f875
feat(#242): Upped ingnite to v29
lxgr-linux Jul 12, 2025
7dc8961
feat(#242): Upped ingnite to v29
lxgr-linux Jul 12, 2025
2f6cbb8
fix(#242): Removed positional params from queries
lxgr-linux Jul 14, 2025
9ec43ae
fix(#242): fixed counting in gtk
lxgr-linux Jul 14, 2025
ec2e181
fix(#242): fixed coin minting module permissions
lxgr-linux Jul 14, 2025
12a3454
feat(#242): Added existance checks to queryWithImage
lxgr-linux Jul 15, 2025
3c628ce
Merge branch 'development' of github.com:DecentralCardGame/Cardchain …
lxgr-linux Jul 15, 2025
9773ea6
Merge pull request #243 from DecentralCardGame/242-cosmos-v50
lxgr-linux Jul 15, 2025
05095e2
feat(#242): Added ignite script
lxgr-linux Jul 15, 2025
d8f19cd
feat(#242): maybe fixed script
lxgr-linux Jul 15, 2025
94d1d20
feat(#242): fixed version
lxgr-linux Jul 16, 2025
2bf71f5
feat(#242): fixed script for encounters
lxgr-linux Jul 16, 2025
a458ab6
fix(#242): Fixed address prefixes in chain
lxgr-linux Jul 17, 2025
8da3e27
fix(#242): Upped to v53
lxgr-linux Jul 17, 2025
f005033
feat(#242): gitignore deugger
lxgr-linux Jul 18, 2025
2603bfd
fixed user creation
lxgr-linux Jul 24, 2025
42e57be
fix: added encounterId to encounterWithImage route
lxgr-linux Jul 30, 2025
f13952b
feat(#261): Updated to v53.5
lxgr-linux Feb 1, 2026
7adf858
feat(#261): updated ignite script
lxgr-linux Feb 1, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
5 changes: 5 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[*.proto]
indent_style = space
trim_trailing_whitespace = false
indent_size = 2
tab_width = 2
20 changes: 11 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#
# This type of prelease is useful to make your bleeding-edge binaries available to advanced users.
#
# The workflow will not run if there is no tag pushed with a "v" prefix and no change pushed to your
# The workflow will not run if there is no tag pushed with a "v" prefix and no change pushed to your
# default branch.
on: push

Expand All @@ -22,19 +22,21 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Prepare Release Variables

- name: Prepare Release Variables
id: vars
uses: ignite/cli/actions/release/vars@v0.26.1
uses: ignite/cli/actions/release/vars@main

- name: Issue Release Assets
uses: ignite/cli/actions/cli@v0.26.1
- name: Issue Release Assets
uses: ignite/cli/actions/cli@main
if: ${{ steps.vars.outputs.should_release == 'true' }}
with:
args: chain build --release --release.prefix ${{ steps.vars.outputs.tarball_prefix }} -t linux:amd64 -t darwin:amd64 --yes
args: chain build --release --release.prefix ${{ steps.vars.outputs.tarball_prefix }} -t linux:amd64 -t darwin:amd64 -t darwin:arm64 -y
env:
DO_NOT_TRACK: 1

- name: Delete the "latest" Release
uses: dev-drprasad/delete-tag-and-release@v0.2.1
uses: dev-drprasad/delete-tag-and-release@v0.2.1
if: ${{ steps.vars.outputs.is_release_type_latest == 'true' }}
with:
tag_name: ${{ steps.vars.outputs.tag_name }}
Expand All @@ -48,6 +50,6 @@ jobs:
with:
tag_name: ${{ steps.vars.outputs.tag_name }}
files: release/*
prerelease: true
prerelease: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
/backup
vue/node_modules
vue/dist
/vue
release/
.idea/
.vscode/
.zed/
.DS_Store
*.dot
*.log
*.ign
/vue
/goat/node_modules
/build
/cs
/goat/node_modules
Expand Down
60 changes: 25 additions & 35 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,58 +1,48 @@
# Use Go 1.23 bookworm as base image
FROM golang:1.23-bookworm AS base

FROM ignitehq/cli:v0.26.1


USER root
RUN apt-get -y -qq update && \
apt-get install -y -qq apt-transport-https curl wget unzip screen bash jq python3 pip && \
apt-get clean

apt-get install -y -qq apt-transport-https curl wget unzip screen bash jq python3 python3-pip python3-venv && \
rm -rf /var/lib/apt/lists/*

# install python script to download genesis
RUN python3 -m venv /opt/venv
ENV PATH="/opt/venv/bin:$PATH"
RUN pip install tendermint-chunked-genesis-download

RUN pip install tendermint-chunked-genesis-download

# install correct go version
RUN if [ $(uname -m) = "x86_64" ]; then \
wget https://go.dev/dl/go1.23.6.linux-amd64.tar.gz; \
tar -xvf go1.23.6.linux-amd64.tar.gz; \
rm /usr/local/go -rf; \
mv go /usr/local; \
elif [ $(uname -m) = "aarch64" ]; then \
wget https://go.dev/dl/go1.23.6.linux-arm64.tar.gz; \
tar -xvf go1.23.6.linux-arm64.tar.gz; \
rm /usr/local/go -rf; \
mv go /usr/local; \
else \
echo "what the hell is your OS? Go will not work that way."; \
fi

# Move to working directory /build
WORKDIR /build

USER tendermint
WORKDIR /home/tendermint
# Copy the go.mod and go.sum files to the /build directory
COPY . .

RUN export GOPATH=$HOME/go
RUN wget https://github.com/DecentralCardGame/go-faucet/archive/master.zip && \
unzip master.zip -d . && cd go-faucet-master && go build

# Install dependencies
RUN go install github.com/lxgr-linux/ignite-vm@latest

# Build the application
RUN ignite-vm install v0.26.2
RUN ignite-vm set v0.26.2

RUN ~/.local/bin/ignite chain init --home /build/.cardchaind
RUN ~/.local/bin/ignite chain build

# Document the port that may need to be published
EXPOSE 1317
EXPOSE 26657
EXPOSE 26658
EXPOSE 9090
EXPOSE 9091
EXPOSE 4500

COPY --chown=tendermint:tendermint . .

RUN ignite chain build --skip-proto
RUN ignite chain init --skip-proto

RUN mv $HOME/.Cardchain $HOME/.cardchaind

COPY scripts/download_genesis.py download_genesis.py
RUN python3 download_genesis.py
RUN cp genesis.json files/
RUN mv genesis.json $HOME/.cardchaind/config/genesis.json
RUN mv genesis.json /build/.cardchaind/config/genesis.json

# Start the application
RUN chmod +x ./docker-run.sh
ENTRYPOINT bash docker-run.sh
ENTRYPOINT bash docker-run.sh
126 changes: 100 additions & 26 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,35 +1,109 @@
###############################################################################
### Build ###
###############################################################################
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
COMMIT := $(shell git log -1 --format='%H')
APPNAME := cardchain

# Default target
all: install
# don't override user values
ifeq (,$(VERSION))
VERSION := $(shell git describe --exact-match 2>/dev/null)
# if VERSION is empty, then populate it with branch's name and raw commit hash
ifeq (,$(VERSION))
VERSION := $(BRANCH)-$(COMMIT)
endif
endif

# Update the ldflags with the app, client & server names
ldflags = -X github.com/cosmos/cosmos-sdk/version.Name=$(APPNAME) \
-X github.com/cosmos/cosmos-sdk/version.AppName=$(APPNAME)d \
-X github.com/cosmos/cosmos-sdk/version.Version=$(VERSION) \
-X github.com/cosmos/cosmos-sdk/version.Commit=$(COMMIT)

BUILD_FLAGS := -ldflags '$(ldflags)'

##############
### Test ###
##############

test-unit:
@echo Running unit tests...
@go test -mod=readonly -v -timeout 30m ./...

test-race:
@echo Running unit tests with race condition reporting...
@go test -mod=readonly -v -race -timeout 30m ./...

# Build directory
BUILDDIR := ./build
test-cover:
@echo Running unit tests and creating coverage report...
@go test -mod=readonly -v -timeout 30m -coverprofile=$(COVER_FILE) -covermode=atomic ./...
@go tool cover -html=$(COVER_FILE) -o $(COVER_HTML_FILE)
@rm $(COVER_FILE)

# Build the project
build: go.sum $(BUILDDIR)/
@echo "Warning: Building without version information"
@echo "Warning: To build with version info and defaults please use './ignite chain build'"
go build -tags=ledger -mod=readonly -o $(BUILDDIR)/ ./...
bench:
@echo Running unit tests with benchmarking...
@go test -mod=readonly -v -timeout 30m -bench=. ./...

# Create the build directory
$(BUILDDIR)/:
mkdir -p $(BUILDDIR)/
test: govet govulncheck test-unit

# Install binary to ~/go/bin/
install: build
cp $(BUILDDIR)/cardchaind ~/go/bin/
.PHONY: test test-unit test-race test-cover bench

# Verify dependencies
go.sum: go.mod
@echo "Ensure dependencies have not been modified ..." >&2
#################
### Install ###
#################

all: install

install:
@echo "--> ensure dependencies have not been modified"
@go mod verify
@echo "--> installing $(APPNAME)d"
@go install $(BUILD_FLAGS) -mod=readonly ./cmd/$(APPNAME)d

.PHONY: all install

##################
### Protobuf ###
##################

# Use this proto-image if you do not want to use Ignite for generating proto files
protoVer=0.15.1
protoImageName=ghcr.io/cosmos/proto-builder:$(protoVer)
protoImage=$(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace $(protoImageName)

proto-gen:
@echo "Generating protobuf files..."
@ignite generate proto-go --yes

.PHONY: proto-gen

#################
### Linting ###
#################

golangci_lint_cmd=golangci-lint
golangci_version=v1.61.0

lint:
@echo "--> Running linter"
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@$(golangci_version)
@$(golangci_lint_cmd) run ./... --timeout 15m

lint-fix:
@echo "--> Running linter and fixing issues"
@go install github.com/golangci/golangci-lint/cmd/golangci-lint@$(golangci_version)
@$(golangci_lint_cmd) run ./... --fix --timeout 15m

.PHONY: lint lint-fix

###################
### Development ###
###################

govet:
@echo Running go vet...
@go vet ./...

# Clean build directory
clean:
rm -rf $(BUILDDIR)/
govulncheck:
@echo Running govulncheck...
@go install golang.org/x/vuln/cmd/govulncheck@latest
@govulncheck ./...

# Phony targets
.PHONY: all build install clean
.PHONY: govet govulncheck
Loading