Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emit "initialized" event when config is ready and commands too #1291

Merged
merged 1 commit into from May 18, 2014

Conversation

azazel75
Copy link
Contributor

I needed a way to put tags data in every page. I cannot use conf.py for that because as i understand Nikola.scan_posts() should be runnable in order to have the data. So i made a SignalHandler plugin hoping to use the "initialized" signal as stated in the docs ( here: http://getnikola.com/extending.html#signalhandler-plugins , but I discovered with a grep that an "initialized" event is never emitted by actual code. So here is a simple patch that emits it when Nikola and the commands are ready to go. I'm not an expert on Nikola's code so feel free to relocate is as long as Nikola.scan_posts() still works when called by a listening SignalHandler's code

@Kwpolska Kwpolska added this to the v7.0.1 milestone May 18, 2014
@Kwpolska Kwpolska self-assigned this May 18, 2014
@Kwpolska Kwpolska merged commit caca4ae into getnikola:master May 18, 2014
Kwpolska added a commit that referenced this pull request May 18, 2014
Signed-off-by: Chris “Kwpolska” Warrick <kwpolska@gmail.com>
@Kwpolska
Copy link
Member

The initialized signal claims to be emitted Right after plugin activation. Which means, pretty much, right before configured is emitted. This will now be changed to fit this.

Kwpolska added a commit that referenced this pull request May 18, 2014
cc @azazel75, via #1291

Signed-off-by: Chris “Kwpolska” Warrick <kwpolska@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants