1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00
Commit graph

9 commits

Author SHA1 Message Date
John Mair
e1088dbc72 after_session in ensure + tests, fixes #418
* + update gemspec
2012-01-14 02:24:13 +13:00
John Mair
2fdfbad039 added Pry::Hooks#dup/merge/merge! and tests 2012-01-12 16:56:41 +13:00
John Mair
1baf8131a0 replaced ineffective :when_started hook test with a better one. Fixed #401 2012-01-04 01:10:09 +13:00
Yorick Peterse
c4f5fdda9e Pass custom options to the when_started hook.
When calling Pry.start() the specified options are passed to the "when_started"
hook. This makes it possible for plugins (combined with commit
b270761efa) to specify their own options without
causing Pry to wet itself.

Signed-off-by: Yorick Peterse <yorickpeterse@gmail.com>
2012-01-02 20:36:39 +01:00
John Mair
c800c0f04f Hook system now executes hooks in order.
Also the return value of exec_hook() is now the value of the last executed hook.
Internally, hooks now use arrays (rather than hash). Also added a get_hooks() method.
Updated tests to reflect these changes.
2011-11-23 18:55:35 +13:00
John Mair
a8677c7937 renamed and refactored some tests for hooks 2011-11-19 14:54:15 +13:00
John Mair
dc7e094e98 added more tests for hooks system 2011-11-17 23:20:07 +13:00
John Mair
263d621625 Hooks now have names, also improved some terminology.
Naming hooks makes them easier to reshuffle and customize.
2011-11-16 02:49:11 +13:00
John Mair
c02772af19 added basic skeleton for hooks system (yet to add many hook callsites) 2011-11-13 02:37:57 +13:00