Skip to content

Commit

Permalink
make check target to check before pushing
Browse files Browse the repository at this point in the history
  • Loading branch information
hrissan authored and Brat-vseznamus committed Jul 12, 2024
1 parent be8ad27 commit 6f8f152
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ TL_BYTE_VERSIONS := ch_proxy.,ab.
all: build

build:
@echo "Building tlgen"
@$(GO) build -ldflags "$(COMMON_LDFLAGS)" -buildvcs=false -o target/bin/tlgen ./cmd/tlgen

tlo-bootstrap: build
Expand Down Expand Up @@ -147,3 +146,9 @@ cpp_gen: build
cpp:
$(MAKE) cpp_gen
$(MAKE) cpp_build

# target should be as close as possible to github actions used to enable merge
.PHONY: check
check: build
@go test $(shell go list ./cmd/... ./internal/... ./pkg/... | grep -v /internal/tlcodegen/test/gen/)
@go run honnef.co/go/tools/cmd/[email protected] ./... # update version together with github actions
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,16 @@ The TL format is characterized by compactness and high efficiency.
TL is schema-driven format. Tool caled `tlgen` is used to generate structs/classes and (de)serialization methods.


## Running without installation

You can run tool without installation. This is recommended way for most use cases.

```
go run github.com/vkcom/tl/cmd/tlgen@latest <options>
```

For build scripts, you can pin particular version instead of `latest`.

## Installation

Install `tlgen` with the following command
Expand Down

0 comments on commit 6f8f152

Please sign in to comment.