-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b88a213
commit 7ece66e
Showing
27 changed files
with
54 additions
and
42 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
# My notes | ||
# Bloco de Notas | ||
|
||
Eleventy and GitHub Pages to write notes | ||
|
||
## Configure a publishing source | ||
|
||
Under Settings for GitHub Pages, use the `publish_branch` named in `.github/workflows/build.yml` as the publishing source. | ||
Soon... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
const syntaxHighlight = require('@11ty/eleventy-plugin-syntaxhighlight'); | ||
|
||
module.exports = (config) => { | ||
config.addPassthroughCopy('src/assets/images/**/*'); | ||
config.addPassthroughCopy({ 'src/posts/images/**/*': 'assets/images/' }); | ||
|
||
config.addPassthroughCopy('src/assets/css/**/*'); | ||
|
||
config.addLayoutAlias('default', 'default.html'); | ||
config.addLayoutAlias('post', 'post.html'); | ||
|
||
config.addCollection('posts', require('./lib/collections/posts')); | ||
|
||
config.addFilter('readableDate', require('./lib/filters/readableDate')); | ||
|
||
config.addPlugin(syntaxHighlight); | ||
|
||
return { | ||
dir: { | ||
input: 'src', | ||
output: './_site', | ||
layouts: '_layouts', | ||
}, | ||
templateFormats: ['md', 'njk', 'html'], | ||
dataTemplateEngine: 'njk', | ||
// markdownTemplateEngine: 'njk', | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = (coll) => { | ||
return coll.getFilteredByGlob('src/posts/**/*.md').reverse(); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
module.exports = (date) => { | ||
const formatedDate = new Date(date); | ||
formatedDate.setMinutes( | ||
formatedDate.getMinutes() + formatedDate.getTimezoneOffset() | ||
); | ||
|
||
return formatedDate.toLocaleString('pt-BR', { | ||
day: 'numeric', | ||
month: 'long', | ||
year: 'numeric', | ||
}); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.