Giter VIP home page Giter VIP logo

Comments (10)

gajus avatar gajus commented on August 16, 2024 1

Just released v2.2.1, let me know if it solves your issues!

It does.

from javascript.

gajus avatar gajus commented on August 16, 2024

A fairly reasonable one-liner:

apt-get update -y && apt-get install -y python-pip && pip install python-ulid && python -c 'from ulid import ULID; print ULID.new().str'

from javascript.

alizain avatar alizain commented on August 16, 2024

You might have better luck with some one of the two go implementations. They should be available as static binaries with 0 dependencies!

from javascript.

gajus avatar gajus commented on August 16, 2024

Well, what would be the one-liner for those?

from javascript.

alizain avatar alizain commented on August 16, 2024

I have no idea, you'll have to check with those specific projects.

from javascript.

alizain avatar alizain commented on August 16, 2024

FWIW, if you do decide to install node as a dependency, this implementation also has a command line interface, so your one-liner would be:

apt-get install node && npm install -g ulid && ulid

from javascript.

gajus avatar gajus commented on August 16, 2024

FYI For whatever reason ulid install failed.

$ apk add --update nodejs nodejs-npm && npm install -g ulid && export RELEASE_ID=$(ulid)
fetch http://dl-cdn.alpinelinux.org/alpine/v3.6/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.6/community/x86_64/APKINDEX.tar.gz
(1/8) Installing libcrypto1.0 (1.0.2k-r0)
(2/8) Installing libgcc (6.3.0-r4)
(3/8) Installing http-parser (2.7.1-r1)
(4/8) Installing libssl1.0 (1.0.2k-r0)
(5/8) Installing libstdc++ (6.3.0-r4)
(6/8) Installing libuv (1.11.0-r1)
(7/8) Installing nodejs (6.10.3-r1)
(8/8) Installing nodejs-npm (6.10.3-r1)
Executing busybox-1.26.2-r7.trigger
OK: 43 MiB in 20 packages
/usr/bin/ulid -> /usr/lib/node_modules/ulid/bin/cli.js
/usr/lib
`-- [email protected] 

module.js:471
    throw err;
    ^

Error: Cannot find module './dist/ulid.umd.js'
    at Function.Module._resolveFilename (module.js:469:15)
    at Function.Module._load (module.js:417:25)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/usr/lib/node_modules/ulid/bin/cli.js:3:14)
    at Module._compile (module.js:570:32)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)

from javascript.

alizain avatar alizain commented on August 16, 2024

Oh dear, what a silly bug. I'll have it cleared in a moment.

from javascript.

alizain avatar alizain commented on August 16, 2024

Just released v2.2.1, let me know if it solves your issues!

from javascript.

alizain avatar alizain commented on August 16, 2024

A quick note - running ulid on the command line will not output a newline character.

from javascript.

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.