2
1
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2023-12-13 21:00:40 +01:00
Commit graph

822 commits

Author SHA1 Message Date
kirrg001 afa482f5fe Version bump to 1.0.0-rc.1 2017-07-11 16:41:08 +02:00
kirrg001 07e35e3d0b ⬆️ bump dependencies
no issue

- gscan@1.1.3
- grunt-contrib-clean@1.1.0
- grunt-contrib-compress@1.4.3
- grunt-contrib-jshint@1.1.0
- jshint@2.9.5
- mocha@3.4.2
2017-07-11 10:45:43 +02:00
kirrg001 21d7791eae Version bump to 1.0.0-beta.2 2017-06-23 09:58:44 +02:00
kirrg001 6a589f7878 ⬆️ bump dependencies
no issue

- gscan@1.1.2
- body-parser@1.17.2
- debug@2.6.8
- express@4.15.3
- html-to-text@3.3.0
- image-size@0.5.5
- uuid@3.1.0
2017-06-22 19:40:56 +02:00
Kevin Ansfield eec5896d34 Version bump to 1.0.0-beta.1 2017-06-08 20:46:12 +01:00
kirrg001 d823412987 ⬆️ bump dependencies
no issue

- gscan 1.1.1
2017-06-08 16:14:51 +02:00
kirrg001 85ed078df8 ⬆️ gscan 1.1.0 2017-06-06 13:07:50 +07:00
kirrg001 8680099765 🎨 gscan 1.1.0 & optimisations
refs #8222

- differentiate between errors and fatal errors
- use gscan errors in theme middleware
- Adds a new `error()` method to `currentActiveTheme` constructor which will return the errors we receive from gscan
- In middleware, if a theme couldn't be activated because it's invalid, we'll fetch the erros and send them to our error handler. We also use a new property `hideStack` to control, if the stack (in dev mode and if available) should be shown or the gscan errors (in prod mode, or in dev if no stack error)
- In our error handler we use this conditional to send a new property `gscan` to our error theme
- In `error.hbs` we'll iterate through possible `gscan` error objects and render them.
- remove stack printing
- stack for theme developers in development mode doesn't make sense
- stack in production doesn't make sense
- the stack is usually hard to read
- if you are developer you can read the error stack on the server log
- utils.packages: transform native error into Ghost error
- use `onlyFatalErrors` for gscan format and differeniate fatal errors vo.2
- optimise bootstrap error handling
- transform theme is missing into an error
- add new translation key
- show html tags for error.hbs template: rule
2017-06-06 13:07:50 +07:00
Katharina Irrgang 18d2c9fae0 ⬆️ bump minimum node version [4.5.0, 6.9.0] (#8489)
no issue

- the new ember version requires 4.5.0
- i've also bumped node v6, because of the latest security vulnerability report (see https://nodejs.org/en/blog/vulnerability/october-2016-security-releases/)
  "All of these vulnerabilities are considered low-severity for Node.js users, however, users of Node.js v6.x should upgrade at their earliest convenience."
2017-05-29 19:24:38 +01:00
Kevin Ansfield 1a1cc6ba23 Version bump to 1.0.0-alpha.21 2017-05-24 15:15:34 +01:00
Ryan McCarvill 957f51e677 🐝 Allow unbalanced HTML in markdown card. (#8320)
no issue

The simpledom interpreter that the Mobiledoc DOM renderer uses does not allow for unbalanced or incorrect HTML such as that which is entered by a user.

This PR adds a step where the HTML is sanitised and balanced before being passed to simpledom.

- use latest jsdom (+pin version), update yarn.lock, add comments
- don't use node-4 incompatible shorthand method definition
- grab <body> content rather than document content
- update markdown card specs to match markdown-it behaviour
- revert to jsdom 9.12.0 for node 4.x support, close window to free memory
- moved 3rd party libs into render function
2017-05-23 16:15:32 +02:00
kirrg001 b20fb26061 ⬇️️ revert dependencies: knex@0.13.0 to knex@0.12.9
no issue

We have recently merged `knex:0.13.0` into Ghost master.

It was absolutely fine and it works, because yarn is smart. but...
- in case you use `npm` for the installation, the installation of the Ghost dependency fails because of a peer dependency error
- we install 2x knex, which isn't really useful
- bookshelf doesn't actually support knex 0.13.0 yet, see https://github.com/tgriesser/bookshelf/issues/1566
2017-05-22 14:59:21 +02:00
Kevin Ansfield 5d868d14ad replace custom showdown fork with markdown-it (#8451)
refs https://github.com/TryGhost/Ghost-Admin/pull/690, closes #1501, closes #2093, closes #4592, closes #4627, closes #4659, closes #5039, closes #5237, closes #5587, closes #5625, closes #5632, closes #5822, closes #5939, closes #6840, closes #7183, closes #7536

- replace custom showdown fork with markdown-it
- swaps showdown for markdown-it when rendering markdown
- match existing header ID behaviour
- allow headers without a space after the #s
- add duplicate header ID handling
- remove legacy markdown spec
- move markdown-it setup into markdown-converter util
- update mobiledoc specs to match markdown-it newline behaviour
- update data-generator HTML to match markdown-it newline behaviour
- fix Post "converts html to plaintext" test
- update rss spec to match markdown-it newline behaviour
- close almost all related showdown bugs
2017-05-15 18:48:14 +02:00
kirrg001 33c95f4523 ⬆️ bump dependencies
no issue

- express@4.15.2
- body-parser@1.17.1
- uuid@3.0.1
2017-05-12 08:59:09 +01:00
Greenkeeper df8e7f873e Update fs-extra to version 3.0.1 🚀 (#8440)
* chore(package): update fs-extra to version 3.0.1

https://greenkeeper.io/

* chore: yarn.lock
2017-05-10 09:51:54 +02:00
Greenkeeper a3e74b305a Update debug to version 2.6.6 🚀 (#8425)
* chore(package): update debug to version 2.6.6

https://greenkeeper.io/

* chore: yarn.lock
2017-05-10 09:47:23 +02:00
Greenkeeper 7a4d76c57d Update image-size to version 0.5.2 🚀 (#8446)
* chore(package): update image-size to version 0.5.2

https://greenkeeper.io/

* chore: yarn.lock
2017-05-10 09:46:54 +02:00
Greenkeeper 8704cc9169 Update knex to version 0.13.0 🚀 (#8428)
* chore(package): update knex to version 0.13.0

https://greenkeeper.io/

* chore: yarn.lock
2017-05-02 13:43:50 +02:00
Greenkeeper 53cc834cd1 Update mocha to version 3.3.0 🚀 (#8376)
* chore(package): update mocha to version 3.3.0

https://greenkeeper.io/

* chore: yarn.lock
2017-05-02 13:33:47 +02:00
Kevin Ansfield 8a9ed971fa Version bump to 1.0.0-alpha.20 2017-04-25 13:58:19 +01:00
Katharina Irrgang 76bd4fdef6 🙀 Image field naming & new img_url helper (#8364)
* 🙀  change database schema for images
    - rename user/post/tag images
    - contains all the required changes from the schema change

* Refactor helper/meta data
    - rename cover to cover_image
    - also rename default settings to match the pattern
    - rename image to profile_image for user
    - rename image to feature_image for tags/posts

* {{image}} >>> {{img_url}}
    - rename
    - change the functionality
    - attr is required
    - e.g. {{img_url feature_image}}

* gscan 1.0.0
    - update yarn.lock

* Update casper reference: 1.0-changes
    - see 5487b4da8d
2017-04-24 18:21:47 +01:00
Greenkeeper df26e38ccf Update debug to version 2.6.4 🚀 (#8367)
* chore(package): update debug to version 2.6.4

https://greenkeeper.io/

* chore: yarn.lock
2017-04-24 16:37:02 +02:00
Greenkeeper c3403d581a Update ghost-ignition to version 2.8.11 🚀 (#8377)
* chore(package): update ghost-ignition to version 2.8.11

https://greenkeeper.io/

* chore: yarn.lock
2017-04-24 13:21:00 +02:00
Greenkeeper b4c70677d8 Update gscan to version 0.2.4 🚀 (#8368)
* chore(package): update gscan to version 0.2.4

https://greenkeeper.io/

* chore: yarn.lock
2017-04-21 01:26:56 +02:00
Greenkeeper 1ccea56370 Update gscan to version 0.2.3 🚀 (#8344)
* chore(package): update gscan to version 0.2.3

https://greenkeeper.io/

* chore: yarn.lock
2017-04-17 16:04:31 +02:00
Hannah Wolfe e9a537004b Added pre-commit hook to handle submodules (#8302)
refs #8235

Usage:
- for existing development setups: `grunt symlink` (will create the pre-commit symlink)
- for fresh development setups: `npm run init` (symlinking happens as part of the typical set up)

-  Added pre-commit hook to handle submodules
  - Checks to see if there are any submodules about to be committed
  - Output matches closely to `git st` to make it easy to read
  - Requires interaction from the committer to accept that this really should be committed
-  Use grunt symlink to register githooks
  - Grunt symlink will make a link to the pre-commit hook
  - It ONLY does this if there isn't already a pre-commit hook, so won't overwrite anything
  - It does this as part of npm run init, not grunt init, because a release repo would NEVER want this
  - This is a dev tool, that configures the repo for development
2017-04-13 08:26:48 +01:00
Kevin Ansfield 8dae1cd361 Version bump to 1.0.0-alpha.19 2017-04-11 18:20:49 +01:00
Greenkeeper 6a7879d4f8 Update nock to version 9.0.13 🚀 (#8306)
* chore(package): update nock to version 9.0.13

https://greenkeeper.io/

* chore: yarn.lock
2017-04-11 10:26:31 +02:00
Hannah Wolfe a413d70313 Asset amends (#8294)
refs #8221

🔥 Remove ghost=true concept from asset url helper

 💯 Introduce CSS minification with cssnano
- add new grunt-cssnano dependency
- wire up grunt task to minify public/ghost.css

🎨 Rename minification config & hash params
- Change minifyInProduction -> hasMinFile
  - this means this asset should have a .min file available
- Change minifyAssets -> useMinFiles
  - this means that in this env we want to serve .min files if available

🎨 Update public/ghost.css to serve .min for prod
- add the new `hasMinFile` property

🎨 Move minified asset handling to asset_url util
- this logic should be in the util, not the asset helper
- updated tests

📖 Error handler always needs asset helper
- this removes the TODO and adds a more sensible comment
- we also need to update our theme documentation around error templates

🔥 Don't use asset helper in ghost head
- use getAssetUrl util instead!
- removed TODO

📖 Update proxy docs
🎨 Simplify asset helper & add tests
- this refactor is a step prior to moving this from metadata to being a url util
- needed to skip some new tests

🐛 Add missing handler for css file
2017-04-10 11:30:21 +02:00
Greenkeeper 791f1b55df Update gscan to version 0.2.2 🚀 (#8281)
* chore(package): update gscan to version 0.2.2

https://greenkeeper.io/

* chore: yarn.lock
2017-04-06 13:55:10 +02:00
Greenkeeper 9d020c93fc Update icojs to version 0.7.2 🚀 (#8278)
* chore(package): update icojs to version 0.7.2

https://greenkeeper.io/

* chore: yarn.lock
2017-04-05 19:11:09 +02:00
Katharina Irrgang 817b8d09ca 😱 🎨 Refactor storage adapter (#8229)
refs #7687

There are four main changes in this PR:

we have outsourced the base storage adapter to npm, because for storage developers it's annoying to inherit from a script within Ghost
we hacked theme storage handling into the default local storage adapter - this was reverted, instead we have added a static theme storage here
use classes instead of prototyping
optimise the storage adapter in general - everything is explained in each commit

----

* rename local-file-store to LocalFileStorage

I would like to keep the name pattern i have used for scheduling.
If a file is a class, the file name reflects the class name.
We can discuss this, if concerns are raised.

* Transform LocalFileStorage to class and inherit from new base

- inherit from npm ghost-storage-base
- rewrite to class
- no further refactoring, happens later

* Rename core/test/unit/storage/local-file-store_spec.js -> core/test/unit/storage/LocalFileStorage_spec.js

* Fix wrong require in core/test/unit/storage/LocalFileStorage_spec.js

* remove base storage and test

- see https://github.com/kirrg001/Ghost-Storage-Base
- the test has moved to this repo as well

* Use npm ghost-storage-base in storage/index.js

* remove the concept of getStorage('themes')

This concept was added when we added themes as a feature.
Back then, we have changed the local storage adapter to support images and themes.
This has added some hacks into the local storage adapters.
We want to revert this change and add a simple static theme storage.

Will adapt the api/themes layer in the next commits.

* Revert LocalFileStorage

- revert serve
- revert delete

* add storagePath as property to LocalFileStorage

- define one property which holds the storage path
- could be considered to pass from outside, but found that not helpful, as other storage adapters do not need this property
- IMPORTANT: save has no longer a targetDir option, because this was used to pass the alternative theme storage path
- IMPORTANT: exists has now an alternative targetDir, this makes sense, because
  - you can either ask the storage exists('my-file') and it will look in the base storage path
  - or you pass a specific path where to look exists('my-file', /path/to/dir)

* LocalFileStorage: get rid of store pattern

- getUniqueFileName(THIS)
- this doesn't make sense, instances always have access to this by default

* Add static theme storage

- inherits from the local file storage, because they both operate on the file system
- IMPORTANT: added a TODO to consider a merge of themes/loader and themes/storage
- but will be definitely not part of this PR

* Use new static theme storage in api/themes

- storage functions are simplified!

* Add https://github.com/kirrg001/Ghost-Storage-Base as dependency

- tarball for now, as i am still testing
- will release if PR review get's accepted

* Adapt tests and jscs/jshint

* 🐛  fix storage.read in favicon utility

- wrong implementation of error handling

* 🎨  optimise error messages for custom storage adapter errors

* little renaming in the storage utlity

- purpose is to have access to the custom storage instance and to the custom storage class
- see next commit why

* optimise instanceof base storage

- instanceof is always tricky in javascript
- if multiple modules exist, it can happen that instanceof is false

* fix getTargetDir

- the importer uses the `targetDir` option to ensure that images land in the correct folder

* ghost-storage-base@0.0.1 package.json dependency
2017-04-05 15:10:34 +01:00
Greenkeeper b9563ab6af Update moment-timezone to version 0.5.13 🚀 (#8272)
* chore(package): update moment-timezone to version 0.5.13

https://greenkeeper.io/

* chore: yarn.lock
2017-04-05 09:56:39 +02:00
Kevin Ansfield f43a8e4315 Version bump to 1.0.0-alpha.18 2017-04-04 12:45:14 +01:00
Katharina Irrgang a42b233b04 Revert: Update sinon to version 2.1.0 (#8262)
no issue

- https://greenkeeper.io/
- revert because sinon has changed their API obviously and it shows lots of depreaction warnings right now
- as sinon is "just" a testing dependency, i wouldn't spend this time right now and add sinon to the ignore list

* Revert: Update sinon to version 2.1.0
* yarn update
2017-04-04 11:54:48 +01:00
Kevin Ansfield 1cb1ea105c 🛠 switch to using yarn in our Grunt tasks (#8261)
no issue

- use `yarn install` instead of `npm install` in grunt tasks
- remove `grunt deps` and `grunt shell:{shrinkwrap/prune/dedupe}` tasks as they are not needed when using `yarn`
- set `options.npmPath` to `yarn` for subgrunt so it doesn't use `npm install` automatically
- don't remove client contributors files in `grunt clean` - those files are now manually created and should be kept

* 🛠 switch to using yarn in our Grunt tasks
* 🛠 use yarn for `npm run init`, update README
2017-04-04 11:47:12 +01:00
Greenkeeper e348303337 Update bluebird to version 3.5.0 🚀 (#8096)
* chore(package): update bluebird to version 3.5.0

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:48:39 +02:00
Greenkeeper a78ee40f63 Update should to version 11.2.1 🚀 (#8117)
* chore(package): update should to version 11.2.1

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:48:05 +02:00
Greenkeeper f0abb25611 Update debug to version 2.6.3 🚀 (#8151)
* chore(package): update debug to version 2.6.3

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:28:37 +02:00
Greenkeeper 68efdfa4e7 Update moment to version 2.18.1 🚀 (#8207)
* chore(package): update moment to version 2.18.1

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:27:57 +02:00
Greenkeeper c1a67df9e1 Update superagent to version 3.5.2 🚀 (#8208)
* chore(package): update superagent to version 3.5.2

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:19:42 +02:00
Greenkeeper d689559975 Update ghost-ignition to version 2.8.10 🚀 (#8177)
* chore(package): update ghost-ignition to version 2.8.10

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:13:19 +02:00
Greenkeeper ea2afd1823 Update should-http to version 0.1.1 🚀 (#8209)
* chore(package): update should-http to version 0.1.1

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 10:12:37 +02:00
Greenkeeper 157d48588d Update fs-extra to version 2.1.2 🚀 (#8181)
* chore(package): update fs-extra to version 2.1.2

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:49:58 +02:00
Greenkeeper e2b7aead2f Update simple-html-tokenizer to version 0.4.1 🚀 (#8232)
* chore(package): update simple-html-tokenizer to version 0.4.1

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:47:57 +02:00
Greenkeeper c25eff732d Update knex to version 0.12.9 🚀 (#8224)
* chore(package): update knex to version 0.12.9

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:47:09 +02:00
Greenkeeper 11afbbaf41 Update nock to version 9.0.11 🚀 (#8239)
* chore(package): update nock to version 9.0.11

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:46:16 +02:00
Greenkeeper faecc485da Update cors to version 2.8.3 🚀 (#8240)
* chore(package): update cors to version 2.8.3

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:45:42 +02:00
Greenkeeper 373865a641 Update moment-timezone to version 0.5.12 🚀 (#8247)
* chore(package): update moment-timezone to version 0.5.12

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:37:25 +02:00
Greenkeeper 230da89e66 Update sinon to version 2.1.0 🚀 (#8198)
* chore(package): update sinon to version 2.1.0

https://greenkeeper.io/

* chore: yarn.lock
2017-04-04 09:01:26 +02:00