Skip to content

add append option to content helper#6706

Closed
devsnek wants to merge 9 commits intoTryGhost:masterfrom
devsnek:patch-1
Closed

add append option to content helper#6706
devsnek wants to merge 9 commits intoTryGhost:masterfrom
devsnek:patch-1

Conversation

@devsnek
Copy link
Copy Markdown

@devsnek devsnek commented Apr 13, 2016

just stopping with no append is silly. lez fix dis. I added an append option to the helper.
{{content characters="250" append="..."}}
{{content characters="250" append="★"}}
{{content characters="250" append="A LONG TIME AGO..."}}
{{content words="40" append="limiting with words? ohhhhkay...."}}
they all work. well.

it works with all the builds and tests that it says to run. i tested it with different ascii/hex/random things and it never failed.

devsnek added 5 commits April 12, 2016 19:54
just stopping with no append is silly. lez fix dis.
```{{content characters="250" append="..."```
… statement

at this point we can just save some logic and leave things to the try statement. i removed the if statement about whether the variable is declared or not because it will get taken care of by the try statement. #makeitsmall #saveresourecs #savelives
does it really matter how many spaces I have after a line comment? REALLY?????????
@devsnek
Copy link
Copy Markdown
Author

devsnek commented Apr 13, 2016

to be fair the commit labeled "this time it will work" only failed because of the linter.

@ErisDS
Copy link
Copy Markdown
Member

ErisDS commented Apr 13, 2016

Hi @GusCaplan, thanks for swinging by!

Can I please point you at a reply I wrote on a recent, similar, feature-adding PR here and also at the discussion on this issue which is all about the feature you've proposed and this very related issue

TLDR; it's not as simple as it seems but there are some improvements I'd love to see here.

@devsnek
Copy link
Copy Markdown
Author

devsnek commented Apr 13, 2016

@ErisDS I have just added the append option to the excerpt helper, and I plan to add the HTML filter and other features that you mention in 5060 later today.

For the future, I think that one of these should be linked to the other because they do the same thing.

@devsnek
Copy link
Copy Markdown
Author

devsnek commented Apr 13, 2016

travis build 9225 (commit b349156) failed because of apt-get, not my code. take a look

@devsnek
Copy link
Copy Markdown
Author

devsnek commented Apr 14, 2016

i'm moving my content pull and my excerpt pull into seperate PRs so this is now closed.
content PR is here

@devsnek devsnek closed this Apr 14, 2016
@devsnek devsnek deleted the patch-1 branch April 14, 2016 22:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants