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
Sample RSS Feed #255
base: master
Are you sure you want to change the base?
Sample RSS Feed #255
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice PR. I've added a few questions.
|
||
This example uses Metalsmith to create a static site and implements an rss feed of all your posts using the metalsmith-feed and metalsmith-collections plugins. | ||
|
||
## Install Node and Update NPM |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For running locally I'd recommend using nvm/nvm-windows to install node - nvm install node
will install the latest stable version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good to me. Lets make that change.
"metalsmith-layouts": "^1.4.1", | ||
"metalsmith-markdown": "^0.2.1", | ||
"metalsmith-permalinks": "^0.5.0", | ||
"metalsmith-collections": "^0.7.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there mixed tabs and spaces here? Is that why it doesn't line up?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure could be from copy pasting. I'll look into it.
examples/rss-feed/Readme.md
Outdated
}) | ||
.source('./src') | ||
.destination('./build') | ||
.clean(false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the reasoning behind .clean(false)
?
https://github.com/metalsmith/metalsmith#cleanboolean
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In this example clean doesn't really do anything. I had been making a lot of PR's last week and copied a bunch of code for this PR. We can get rid of clean.
examples/rss-feed/Readme.md
Outdated
|
||
2. The `source()` method declares the directory where the files will be pre-manipulation. | ||
3. The `destination()` method declares the destination directory the files will end up post-manipulation. | ||
4. The `clean()` method will delete the contents of the destination directory everytime metalsmith is run and the files are manipulated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't match with .clean(false)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again just overlooked this from another project. We should get rid of it.
629516e
to
9fd4b33
Compare
9d899cc
to
2c5abda
Compare
Created an RSS Feed example. Thought this would help others looking to create an RSS Feed for a static blog they were looking to create with Metalsmith. Something I needed.