Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building create-pkg #404

Closed
darcyclarke opened this issue Sep 4, 2020 · 16 comments
Closed

Building create-pkg #404

darcyclarke opened this issue Sep 4, 2020 · 16 comments
Assignees

Comments

@darcyclarke
Copy link
Member

darcyclarke commented Sep 4, 2020

EDIT by @boneskull: This issue has been moved to pkgjs/create-pkg#9; please comment there

Recently, I was able to transfer the ownership of the create-pkg package over to the @pkgjs org on npmjs.com. The hope here is that this namespace/package can serve as tooling to scaffold new projects with whatever defaults this group wants to define & be unblocked by npm-specific defaults in npm init.

@wesleytodd @ruyadorno & I got together the other day to discuss this a bit more & here's some of the notes from that discussion:

Note: We'd love input & to have a broader discussion about how/what we could build

create-pkg

Goals:

  1. Provide a tool that promotes sane package defaults (defined by PMWG)
  2. Provide tools to extend defaults per community/team

Example Usage:

$ npm init pkg
$ npx create-pkg
const pkg = require('create-pkg')
import pkg from 'create-pkg'

Questions:

  1. What do we want the scaffold output to include?
    • package.json
      • name
      • description
      • homepage
      • author
      • license
      • funding
      • version
      • type
      • main
      • scripts
        • "prepublish": "..."* (contentious)
        • "test": "..."* (contentious)
      • exports
    • index.js
    • LICENSE
    • CONTRIBUTING.md
    • CODE_OF_CONDUCT.md
    • README.md
    • FUNDING.yml* (contentious)
    • .npmrc* (contentious)
    • .gitignore* (contentious)
      • Contents: /node_modules
    • .github/ISSUE_TEMPLATES/** (contentious)
  2. What API surface do we want to expose to both end users and folks who want to compose the base generator with their own custom opinions?
    • Interfaces: CLI w/ Interactive/Prompts & a JS API

Next Steps:

  • Get some general consensus of the approach we'd like to take building this & the defaults we'd want
  • Update @pkgjs/support to be a consumer of this tool or vice-versa

References & Prior Art:

@darcyclarke darcyclarke added the package-maintenance-agenda Agenda items for package-maintenance team label Sep 4, 2020
@mhdawson
Copy link
Member

mhdawson commented Sep 8, 2020

In meeting was mentioned that

CONTRIBUTORS.md

should be

CONTRIBUTING.md

@Christian24
Copy link

I hope this is the correct place to post this: Since npm v7 supports workspaces, it would be helpful to have a variant of this potentially be able to setup workspaces/monorepositories too. Maybe some inspiration can be drawn from https://github.com/lerna/lerna/tree/master/commands/init#readme. I probably cannot attend tomorrow, but since I just heard about this at the npm RFC meeting, I thought I would drop it here.

@wesleytodd
Copy link
Member

While I am not sure that would be a top priority for the first iteration, I completely agree that it should be a feature of this tool.

@ruyadorno
Copy link
Member

@wesleytodd please remember to also add me to the org 😊

@thescientist13
Copy link
Contributor

Count me in to help on next steps @wesleytodd ! 👋

@rxmarbles
Copy link
Contributor

@wesleytodd ditto for me as well

@rodion-arr
Copy link
Contributor

Will be happy to help here

@wesleytodd
Copy link
Member

This one is waiting on me, I have I think all of the code on my machine, just need to run through it and push. Sorry for the delay, I will try to get to it this week.

@boneskull
Copy link

I'm looking for some more context on this. @darcyclarke describes what the package is intended to do, but does not describe what lead the team to want to build this.

@boneskull
Copy link

For scripts.test, I like "echo \"Error: no test specified\" && exit 1" 😄

@mhdawson
Copy link
Member

mhdawson commented Dec 1, 2020

@wesleytodd any chance you could just push what you have, warts and all ?

@wesleytodd
Copy link
Member

After pushing I noticed a few things wrong with what I pushed, but here is the start: https://github.com/pkgjs/create

@boneskull
Copy link

@boneskull move this list into pkgjs/create repo

@boneskull
Copy link

@wesleytodd your friendly 🙂😁😄😜 reminder to move create-package-json etc. into pkgjs org

@boneskull boneskull removed the package-maintenance-agenda Agenda items for package-maintenance team label Jan 12, 2021
@boneskull
Copy link

boneskull commented Jan 12, 2021

Closing in lieu of pkgjs/create-pkg#9

To anyone who wants to help move this forward, please see that issue/repo.

@boneskull
Copy link

Maybe we should keep this open as a "tracking" issue for package-maintenance-agenda? IDK. It should still probably stay on the agenda... new issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants