kimmobrunfeldt / git-hours

Estimate time spent on a git repository
MIT License
772 stars 59 forks source link

403 tar.gz #32

Closed rngadam closed 3 years ago

rngadam commented 6 years ago
403 status code downloading tarball https://nodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.13.2-node-v51-darwin-x64.tar.gz

with a browser, I get:

<Error>
<script/>
<Code>AccessDenied</Code>
<Message>Access Denied</Message>
<RequestId>B07936DF9D117468</RequestId>
<HostId>
wbKl516JO34MDKT4VgxSkm+xjMErxW2PAeXar+WIsYrakX66/gxvleGnnkQhB5gxUfe4v5g5xWY=
</HostId>
</Error>
shengslogar commented 6 years ago

@rngadam Download the repo and open package.json.

Change line 32: "nodegit": "^0.13.2" to "nodegit": ">=0.13.2". Open your terminal, navigate to the correct parent directory, and run npm install git-hours-master -g.

Do a party dance.

rngadam commented 6 years ago

Hmm, tried what I think is somewhat close

git clone https://github.com/kimmobrunfeldt/git-hours
vi package.json
cd ..
npm install -g ./git-hours

get this:

Error: dlopen(/usr/local/lib/node_modules/git-hours/node_modules/nodegit/build/Release/nodegit.node, 1): no suitable image found.  Did find:
    /usr/local/lib/node_modules/git-hours/node_modules/nodegit/build/Release/nodegit.node: truncated mach-o error: segment __TEXT extends to 4730880 which is past end of file 2032640
    /usr/local/lib/node_modules/git-hours/node_modules/nodegit/build/Release/nodegit.node: truncated mach-o error: segment __TEXT extends to 4730880 which is past end of file 2032640
shengslogar commented 6 years ago

Looks like I might've been lucky. Trying the exact same thing this morning and it's not working. Can't crack this one. (Literally still have that repo from last night, and commands don't work straight on that. Cloning your way, I get permission errors, which is super weird even though I'm running with full admin rights.)

vheathen commented 6 years ago

I was able to install this package with the next steps:

  1. Install current nodegit with npm install -g nodegit (believe it is unnecessary)
  2. By @shengslogar advice: clone repo and change strict nodegit version to ">=0.13.2"
  3. While in the repo directory install local packages with npm install
  4. Go up and try to install globally with npm install -g ./git-hours

Now it works like a charm:

/m/c/c/D/P/J/p/profile @ master … > git-hours -a 60 { "v.heathen@gmail.com": { "name": "heathen", "hours": 179, "commits": 337 }, "total": { "hours": 179, "commits": 337 } }

kimmobrunfeldt commented 3 years ago

After new release 1.5.0, npx git-hours works again! Tested with node 14, macOS. The node version is probably quite specific.