Permalink
Browse files

add @hhirsch back to ©

Signed-off-by: Chris Warrick <kwpolska@gmail.com>
  • Loading branch information...
Kwpolska committed Jan 10, 2015
1 parent f96b7b0 commit 270b37632acb4c01ea34bfb23bbe6eb7fba36de3
Showing with 34 additions and 23 deletions.
  1. +1 −1 LICENSE
  2. +1 −1 comet/__init__.py
  3. +10 −6 comet/__main__.py
  4. +1 −1 comet/data/comet_assets/css/comet.css
  5. +1 −1 comet/data/comet_assets/js/comet.js
  6. +2 −1 comet/init.py
  7. +16 −8 comet/web.py
  8. +1 −1 docs/LICENSE.rst
  9. +1 −1 docs/conf.py
  10. +0 −2 docs/web.rst
View
@@ -1,4 +1,4 @@
Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
View
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
# Comet CMS v0.6.0
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
# Permission is hereby granted, free of charge, to any
# person obtaining a copy of this software and associated
View
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
# Comet CMS v0.6.0
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
# Permission is hereby granted, free of charge, to any
# person obtaining a copy of this software and associated
@@ -48,9 +48,11 @@
__doc__ = __doc__.format(comet.__version__)
def main():
u"""The main function."""
arguments = docopt.docopt(__doc__, version=u'Comet CMS v{0}'.format(comet.__version__))
arguments = docopt.docopt(__doc__, version=u'Comet CMS v{0}'.format(
comet.__version__))
if arguments[u'init']:
sys.exit(init(arguments))
elif arguments[u'devserver']:
@@ -61,16 +63,18 @@ def init(arguments):
import comet.init
return comet.init.init()
def devserver(arguments):
import comet.web
port = int(arguments[u'port'])
port = int(arguments['--port'])
url = 'http://localhost:{0}/'.format(port)
comet.web.configure_site(url)
comet.web.configure_url(url)
comet.web.app.config['DEBUG'] = True
if arguments[u'browser']:
if arguments['--browser']:
webbrowser.open(url)
comet.web.app.logger.info(u"Comet CMS running @ http://localhost:8001/")
comet.web.app.logger.info(u"Comet CMS running @ {0}".format(url))
comet.web.app.run('localhost', port, debug=True)
return 0
@@ -1,5 +1,5 @@
/*
* Copyright © 2014-2015, Chris Warrick et al.
* Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
* See /LICENSE for licensing information.
*/
@@ -1,5 +1,5 @@
/*
* Copyright © 2014-2015, Chris Warrick et al.
* Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
* See /LICENSE for licensing information.
*/
View
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
# Comet CMS v0.6.0
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
# Permission is hereby granted, free of charge, to any
# person obtaining a copy of this software and associated
@@ -27,6 +27,7 @@
from __future__ import print_function, unicode_literals
def init():
print("ERROR: Not implemented.")
return 255
View
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
# Comet CMS v0.6.0
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
# Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
# Permission is hereby granted, free of charge, to any
# person obtaining a copy of this software and associated
@@ -51,7 +51,13 @@ def scan_site():
nikola.utils.LOGGER.info("Posts scanned.")
def configure_site(url=None):
def configure_url(url):
"""Configure site URL."""
app.config['COMET_URL'] = site.config['SITE_URL'] =\
site.config['BASE_URL'] = site.GLOBAL_CONTEXT['blog_url'] = url
def configure_site():
"""Configure the site for Comet."""
global site
@@ -99,19 +105,19 @@ def configure_site(url=None):
else:
raise Exception("Not a Nikola site.")
app.secret_key = site.config['COMET_SECRET_KEY']
app.config['COMET_URL'] = url or site.config['COMET_URL']
app.secret_key = site.config.get('COMET_SECRET_KEY')
app.config['COMET_URL'] = site.config.get('COMET_URL')
read_users()
site.template_hooks['menu_alt'].append(generate_menu_alt)
app.config['NIKOLA_URL'] = site.config['SITE_URL']
site.config['SITE_URL'] = site.config['BASE_URL'] =\
site.GLOBAL_CONTEXT['blog_url'] = app.config['COMET_URL']
configure_url(app.config['COMET_URL'])
site.config['NAVIGATION_LINKS'] = {
'en': (
(app.config['NIKOLA_URL'], '<i class="fa fa-globe"></i> Back to website'),
(app.config['NIKOLA_URL'],
'<i class="fa fa-globe"></i> Back to website'),
('/rebuild', '<i class="fa fa-cog rebuild"></i> Rebuild'),
)
}
@@ -566,7 +572,6 @@ def delete():
return redirect('/')
@app.route('/rebuild')
@login_required
def rebuild():
@@ -581,6 +586,7 @@ def rescan():
scan_site()
return redirect('/')
@app.route('/wysihtml/<path:path>')
def serve_wysihtml(path):
"""Serve wysihtml files.
@@ -823,3 +829,5 @@ def display_permission(user, permission):
'action': action,
'json': json,
'display_permission': display_permission})
configure_site()
View
@@ -2,7 +2,7 @@
Appendix C. License
===================
Copyright © 2014-2015 Chris Warrick, Roberto Alsina et al.
Copyright © 2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
View
@@ -48,7 +48,7 @@
# General information about the project.
project = 'Comet CMS'
copyright = '2014-2015, Chris Warrick and the Comet contributors'
copyright = '2014-2015 Chris Warrick, Roberto Alsina, Henry Hirsch et al.'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
View
@@ -2,9 +2,7 @@
Internals
=========
This is the documentation of ``comet.web``, which is the heart of Comet CMS.
.. index:: internals
.. versionadded:: 0.6.0
.. automodule:: comet.web
:members:

0 comments on commit 270b376

Please sign in to comment.