Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

A CLI for publishing sites to Netlify and assigning custom subdomains to them.

License

NotificationsYou must be signed in to change notification settings

zevaverbach/publify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

The coolest thingpublify can do is publish a folder of static web pages and supporting assets to the web using Netlify, including adding a custom subdomain!

Here's the full menu, though, with more details under the headings below:

> pubhelpUsage:    pubhelp    pub<rootpath> [<custom_domain>]             --------------------------------> deploy a site    pub list                                     -------------------------------> list all sites    pub custom<custom_domain><existing_domain> -------------------------->set a custom domain    pub remove-custom<custom_domain>            -----------------------> remove a custom domain    pub delete/remove<domain or custom_domain>  --------------------------------> delete a site

Publish Sites to Netlify via CLI!

> ls mysite└── folder    ├── index.html    ├── another_page.html    ├── styles.css    └── a.jpg>> pub mysite/the site is published: http://6426ed336771f2380224fb84--scintillating-mochi-760bd3.netlify.app

Publish Sites to Netlify With Custom Subdomains Too!

> pub mysite dude.helpers.funthe site is published: http://6426ee6a10e4e43866b46a42--startling-gingersnap-425138.netlify.appthe site is published at dude.helpers.fun.

If you only have one domain set up with Netlify, there's no need to include anything but the subdomain part:

> pub mysite/ dudettethe site is published: http://642718842cb34f02bc6b0137--cheery-daifuku-f3417f.netlify.appthe site is published at dudette.helpers.fun.

List All Your Sites!

> pub listsites without custom domains:cheery-daifuku-f3417f: https://cheery-daifuku-f3417f.netlify.apppreeminent-salamander-6262a7: http://preeminent-salamander-6262a7.netlify.appscintillating-mochi-760bd3: https://scintillating-mochi-760bd3.netlify.apptranscribely: https://transcribely.netlify.appsites with custom domains:euphonious-torrone-029b78: https://shucks.helpers.funflourishing-sherbet-8f356e: https://dudettes.helpers.funbeautiful-meerkat-95c24f: https://duasdfdes.helpers.funglittery-khapse-b51104: https://dudes.helpers.funvelvety-cobbler-d4e023: https://mama.helpers.funplayful-treacle-6fea54: https://okay.helpers.funcalm-dodol-b7aea3: https://thedonkey.helpers.fun

Add A Custom Subdomain To An Already Published Site!

> pub custom hey.helpers.fun preeminent-salamander-6262a7.netlify.appthe site is published at hey.helpers.fun. (originally'preeminent-salamander-6262a7.netlify.app')

You can also provide partial names for the Netlify URLs, and also for the custom domains if you only have one domain listed inNETLIFY_DOMAINS:

> pub custom hey preeminentthe site is published at hey.helpers.fun. (originally'preeminent-salamander-6262a7.netlify.app')

Remove a Custom Subdomain!

> pub remove-custom hey'hey.helpers.fun' was removed

Delete An Entire Site!

Powerful stuff:

> pub delete preeminentsite'http://preeminent-salamander-6262a7.netlify.app' was deleted

But First, a Bit of Configuration

To do this magic, you have to first

  1. Create an environment variableNETLIFY_TOKEN, obtainedhere.
  2. Create an environment variableNETLIFY_DOMAINS, with comma-separated values (no spaces), if you're planning to use custom domains.
  3. Delegate DNS management of all domains listed inDOMAINS to Netlify (link)

TODO

  • add some color and spinners to the CLI using Rich

About

A CLI for publishing sites to Netlify and assigning custom subdomains to them.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp