pages-store
v0.2.2
Published
GitHub Pages Storage Adapter for Ghost
Downloads
8
Readme
pages-store
GitHub Pages Storage Adapter for Ghost
Installation
Via Yarn or NPM
Install pages-store module
yarn add pages-store # or npm npm install pages-store
Make the storage folder if it doesn't exist yet
mkdir -p content/adapters/storage
Copy the module into the right location
cp -vR node_modules/pages-store content/adapters/storage/pages-store
Via Git
In order to replace the storage module, the basic requirements are:
Create a new folder inside
content/adapters
calledstorage
Clone this repo to
storage
cd [path/to/ghost]/content/adapters/storage git clone https://github.com/zce/pages-store.git
Install dependencies
cd pages-store yarn # or npm install
Usage
In your config.[env].json
file, you'll need to add a new storage
block to whichever environment you want to change:
{
"storage": {
"active": "pages-store",
"pages-store": {
"prefix": "http://zce.github.io/storage",
"repo": "zce/storage"
}
}
}
Options
{
"storage": {
"active": "pages-store",
"pages-store": {
"repo": "https://git.coding.net/zce/images.git",
"branch": "master",
"prefix": "https://img.zce.me",
"format": "{yyyy}/{mm}/{dd}/{name}-{uuid}-{timestamp}-{random}{ext}"
}
}
}
Authorization
You can use URL authentication:
https://<TOKEN>@github.com/zce/images.git
https://wedn:<TOKEN>@git.coding.net/wedn/images.git
Contributing
- Fork it on GitHub!
- Clone the fork to your own machine.
- Checkout your feature branch:
git checkout -b my-awesome-feature
- Commit your changes to your own branch:
git commit -am 'Add some feature'
- Push your work back up to your fork:
git push -u origin my-awesome-feature
- Submit a Pull Request so that we can review your changes.
NOTE: Be sure to merge the latest from "upstream" before making a pull request!