Comments (22)
I like it. This definitely needs some tests and features built in if you want it included.
from jekyll.
I'll gladly write the tests. Can you elaborate on what you mean by "features built in" so I can move forward on getting this integrated?
Sorry about the dup msg...
from jekyll.
No problem. I meant a Cucumber feature/integration test for this, just to ensure that it works as expected.
from jekyll.
Another issue with this: some sort of secure: false
flag should be necessary to enable this feature. Since Jekyll is in charge of generating the GitHub pages, we can't let just anyone to execute whatever they'd like on the server. For most users generating posts though, this behavior is extremely useful.
from jekyll.
That shouldn't be hard to implement. I'll add it in my fork.
from jekyll.
I added support for a _liquid_tags directory along with a config param "liquid_tags" that defaults to false. Also added two tests to test_site. It may be worth breaking the "should load external tags" test into its own context since it uses its own site with a different config. Let me know what you think.
http://github.com/n8agrin/jekyll/commit/dfd5ef02b4c0edf59476aa15b472a0a5ab9980ee
from jekyll.
I see this is on hold. Anything else I can do to help it get through?
from jekyll.
There's been no work done towards an insecure/secure mode yet. I'd like to see that in the lib first. The same conditions apply as my earlier comment.
from jekyll.
Ah ok, I didn't interpret your earlier request as you literally wanted a "secure: false" flag implemented. I took that to mean you wanted the option to turn importing custom tags on and off, hence the liquid_tags config param. My mistake, shouldn't be hard to get a secure flag working.
from jekyll.
What's holding this back? It seems like it has a command line flag to turn it on or off. why isn't that enough?
from jekyll.
While I realize people are working on this (sorry to be impatient!), I have come up with a temporary solution for those that are interested:
http://benjaminthomas.org/2009/10/21/custom-liquid-tags-in-jekyll.html
from jekyll.
Cool. I just bumped this here: http://github.com/n8agrin/jekyll/commit/4b82e06f8b0ee153149edc803abd297d50539b41 Hopefully that's should cover everything.
from jekyll.
Summary of changes:
- Changed liquid_tags flag to "secure", secure is set to true by default
- Added if block that checks the secure flag, if it's false, liquid tags (and presumably other insecure code) can be loaded.
- Added tests for the liquid tags.
I'm not terribly happy with the line that reads "load file unless require file", I may change that to just "load file".
Please review and let me know if there are issues which need to be resolved before this can be merged.
from jekyll.
Hi,
I've just implemented custom tags http://github.com/jodosha/jekyll/commit/6fb67d35fb714a063571a3e5c8819650e6fc7090 and custom Liquid filters http://github.com/jodosha/jekyll/commit/68861c5a5ac6bedb3b8670a56ac684b043912c95
from jekyll.
Are there any issues left that need to be tackled?
from jekyll.
None that I know of. We have 3 implementations, each of which seem fine. Unclear to me what's holding this oft-requested feature up.
from jekyll.
+1 to this feature, it'd be really nice to have the option to extend jekyll sites without forking and building my own gem.
from jekyll.
#100 addresses this nicely too in a generic extensions way as requested by qrush.
from jekyll.
I've come up with another solution (http://github.com/rfelix/jekyll_ext) that not only allows you to easily add liquid tags for your blog, but also allows you to extend Jekyll without forking and modifying the gem's codebase.
The extensions live under the "_extensions" directory of your blog, and this is how easy it is to add custom liquid tags: http://github.com/rfelix/my_jekyll_extensions/blob/master/my_filters/my_filters.rb
Read my post about it for more information: http://rfelix.com/2010/01/19/jekyll-extensions-minus-equal-pain/
from jekyll.
The latest on master now has Plugin support. Look at lib/jekyll/converters for examples of how they're done. Also, any *.rb files in a _plugins directory will be loaded so that you can create custom plugins of your own.
from jekyll.
I've readed the source code but can't figure out how the plugins are supposed to work. I'd appreciate some orientation on that respect (maybe updating of the "hacking jekyll" wiki page)
from jekyll.
I see that the new page is created ( http://wiki.github.com/mojombo/jekyll/plugins ). Thanks!
from jekyll.
Related Issues (20)
- Update dependency constraint to allow for activesupport v7.1.1 HOT 2
- feat: multi-thread rendering HOT 10
- [Bug]: jekyll build fails with Variable was not properly terminated with regexp: /\\}\\}/ (Liquid::SyntaxError) HOT 1
- [Bug]: jekyll not working after upgrade from Debian 11 to 12 HOT 2
- [Bug]: Jekyll Github Pages site doesn't "play nice" with Ruby versions required by vscode HOT 1
- Time for a new release
- > Β‘Hola! π HOT 1
- feat: OpenBSD support HOT 6
- Found CRITICAL Vulnerability in your website! HOT 1
- [Bug]: LiveReload websocket crashes over HTTPS/WSS HOT 1
- [Bug]: jekyll serve does not detach when spawned without shell HOT 1
- [Docs]: Urgent: Specify json gem version for Jekyll 4.3.2
- [Bug]: livereload-ignore option doesn't work HOT 1
- [Bug]: Liquid Exception: divided by 0
- [Docs]: 7. Assets - css-lcurlyexcted
- feat: Display the deployed package in the repository
- [Docs]: GitHub Pages relative links note
- feat: TOML front matter support HOT 3
- feat:
- [Bug]: `page` variables to not rendered correctly HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jekyll.