Giter VIP home page Giter VIP logo

Comments (7)

JonasVautherin avatar JonasVautherin commented on June 21, 2024

However, this still requires installing goatcounter

Just fetch it from the releases

from goatcounter.

arp242 avatar arp242 commented on June 21, 2024

You need to use go run ./cmd/goatcounter, rather than go run ., as that contains the package main.

But as mentioned: I would recommend using a release build unless you have a very specific reason not to.

from goatcounter.

zigomi avatar zigomi commented on June 21, 2024

But as mentioned: I would recommend using a release build unless you have a very specific reason not to.

Why would I run a release locally?

./goatcounter-v2.5.0-linux-amd64 serve -dev
goatcounter-v2.5.0-linux-amd64: -dev flag was given but this doesn't seem like a GoatCounter source directory

from goatcounter.

arp242 avatar arp242 commented on June 21, 2024

You need to run it from the source directory when you use -dev Because it loads some things from the filesystem. It's really just intended for development.

from goatcounter.

zigomi avatar zigomi commented on June 21, 2024

I don't remember how I mananged to run it a half a year ago. Now

(1)

 % pwd
/home/me/projects/var/goatcounter

% go run cmd/goatcounter 
package cmd/goatcounter is not in std (/usr/lib/go/src/cmd/goatcounter)

Other Go projects will run and compile no issue, as well as go fmt, for instance. So go is set up properly.

(2)

a release goatcounter-v2.5.0-linux-amd64 serve shouldn't be in the dev mode and from the source directory because why would one want to run it? A release should be run in the prod. Or locally but without -dev, right?

from goatcounter.

zigomi avatar zigomi commented on June 21, 2024

aaaaaah

I've just compiled it and this his resolved the issue.

from goatcounter.

arp242 avatar arp242 commented on June 21, 2024

a release goatcounter-v2.5.0-linux-amd64 serve shouldn't be in the dev mode and from the source directory because why would one want to run it? A release should be run in the prod. Or locally but without -dev, right?

Yes; the -dev flag is really only intended if you want to do development. For example it will read the template files from disk so you don't need to recompile on changes. Things like that.

Normally you shouldn't even need the goatcounter source directory; just the release binary (or a binary you built yourself) is enough.

% go run cmd/goatcounter 
package cmd/goatcounter is not in std (/usr/lib/go/src/cmd/goatcounter)

This should be go run ./cmd/goatcounter. Without that ./ it will assume it's in the standard library, rather than local to your current directory.

from goatcounter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.