File tree Expand file tree Collapse file tree 27 files changed +35
-35
lines changed Expand file tree Collapse file tree 27 files changed +35
-35
lines changed Original file line number Diff line number Diff line change
1
+ [run]
2
+ source = pyramid_app
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change 1
1
include *.txt *.ini *.cfg *.rst
2
- recursive-include pyramid_html *.ico *.png *.css *.gif *.jpg *.pt *.txt *.mak *.mako *.js *.html *.xml *.jinja2
2
+ recursive-include pyramid_app *.ico *.png *.css *.gif *.jpg *.pt *.txt *.mak *.mako *.js *.html *.xml *.jinja2
3
3
recursive-include tests *
4
4
recursive-exclude * __pycache__
5
5
recursive-exclude * *.py[co]
Original file line number Diff line number Diff line change 1
- # pyramid-html
1
+ # pyramid-app
2
2
3
3
4
4
## Introduction
@@ -8,8 +8,8 @@ This project got initialized by using `cookiecutter`.
8
8
``` bash
9
9
$ cookiecutter gh:Pylons/pyramid-cookiecutter-starter
10
10
11
- [1/4] project_name (Pyramid Scaffold): pyramid-html
12
- [2/4] repo_name (pyramid_html ):
11
+ [1/4] project_name (Pyramid Scaffold): pyramid-app
12
+ [2/4] repo_name (pyramid_app ):
13
13
[3/4] Select template_language
14
14
1 - jinja2
15
15
2 - chameleon
@@ -30,10 +30,10 @@ Welcome to Pyramid. Sorry for the convenience.
30
30
===============================================================================
31
31
32
32
Change directory into your newly created project.
33
- cd pyramid-html
33
+ cd pyramid-app
34
34
35
35
Create a Python virtual environment.
36
- python3 -m venv env
36
+ python3 -m venv .venv
37
37
38
38
Upgrade packaging tools.
39
39
env/bin/pip install --upgrade pip setuptools
Original file line number Diff line number Diff line change 4
4
# ##
5
5
6
6
[app:main]
7
- use = egg:pyramid_html
7
+ use = egg:pyramid_app
8
8
9
9
pyramid.reload_templates = true
10
10
pyramid.debug_authorization = false
@@ -32,7 +32,7 @@ listen = localhost:6543
32
32
# ##
33
33
34
34
[loggers]
35
- keys = root, pyramid_html
35
+ keys = root, pyramid_app
36
36
37
37
[handlers]
38
38
keys = console
@@ -44,10 +44,10 @@ keys = generic
44
44
level = INFO
45
45
handlers = console
46
46
47
- [logger_pyramid_html ]
47
+ [logger_pyramid_app ]
48
48
level = DEBUG
49
49
handlers =
50
- qualname = pyramid_html
50
+ qualname = pyramid_app
51
51
52
52
[handler_console]
53
53
class = StreamHandler
Original file line number Diff line number Diff line change 4
4
# ##
5
5
6
6
[app:main]
7
- use = egg:pyramid_html
7
+ use = egg:pyramid_app
8
8
9
9
pyramid.reload_templates = false
10
10
pyramid.debug_authorization = false
@@ -26,7 +26,7 @@ listen = *:6543
26
26
# ##
27
27
28
28
[loggers]
29
- keys = root, pyramid_html
29
+ keys = root, pyramid_app
30
30
31
31
[handlers]
32
32
keys = console
@@ -38,10 +38,10 @@ keys = generic
38
38
level = WARN
39
39
handlers = console
40
40
41
- [logger_pyramid_html ]
41
+ [logger_pyramid_app ]
42
42
level = WARN
43
43
handlers =
44
- qualname = pyramid_html
44
+ qualname = pyramid_app
45
45
46
46
[handler_console]
47
47
class = StreamHandler
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change 6
6
<meta name =" viewport" content =" width=device-width, initial-scale=1.0" >
7
7
<meta name =" description" content =" pyramid web application" >
8
8
<meta name =" author" content =" Pylons Project" >
9
- <link rel =" shortcut icon" href =" {{request.static_url('pyramid_html :static/pyramid-16x16.png')}}" >
9
+ <link rel =" shortcut icon" href =" {{request.static_url('pyramid_app :static/pyramid-16x16.png')}}" >
10
10
11
11
<title >Cookiecutter Starter project for the Pyramid Web Framework</title >
12
12
13
13
<!-- Bootstrap core CSS -->
14
14
<link rel =" stylesheet" href =" //maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity =" sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin =" anonymous" >
15
15
16
16
<!-- Custom styles for this scaffold -->
17
- <link href =" {{request.static_url('pyramid_html :static/theme.css')}}" rel =" stylesheet" >
17
+ <link href =" {{request.static_url('pyramid_app :static/theme.css')}}" rel =" stylesheet" >
18
18
19
19
<!-- HTML5 shiv and Respond.js IE8 support of HTML5 elements and media queries -->
20
20
<!-- [if lt IE 9]>
29
29
<div class =" container" >
30
30
<div class =" row" >
31
31
<div class =" col-md-2" >
32
- <img class =" logo img-responsive" src =" {{request.static_url('pyramid_html :static/pyramid.png') }}" alt =" pyramid web framework" >
32
+ <img class =" logo img-responsive" src =" {{request.static_url('pyramid_app :static/pyramid.png') }}" alt =" pyramid web framework" >
33
33
</div >
34
34
<div class =" col-md-10" >
35
35
{% block content %}
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change 3
3
4
4
@view_config (
5
5
route_name = 'home' ,
6
- renderer = 'pyramid_html :templates/home.jinja2'
6
+ renderer = 'pyramid_app :templates/home.jinja2'
7
7
)
8
8
def home (request ):
9
- return {'project' : 'pyramid-html ' }
9
+ return {'project' : 'pyramid-app ' }
10
10
11
11
12
12
@view_config (
13
13
route_name = 'about' ,
14
- renderer = 'pyramid_html :templates/about.jinja2'
14
+ renderer = 'pyramid_app :templates/about.jinja2'
15
15
)
16
16
def about (request ):
17
17
return {'message' : 'About pyramid.' }
Original file line number Diff line number Diff line change 1
1
from pyramid .view import notfound_view_config
2
2
3
3
4
- @notfound_view_config (renderer = 'pyramid_html :templates/404.jinja2' )
4
+ @notfound_view_config (renderer = 'pyramid_app :templates/404.jinja2' )
5
5
def notfound_view (request ):
6
6
request .response .status = 404
7
7
return {}
Original file line number Diff line number Diff line change 2
2
addopts = --strict-markers
3
3
4
4
testpaths =
5
- pyramid_html
5
+ pyramid_app
6
6
tests
Original file line number Diff line number Diff line change 23
23
]
24
24
25
25
setup (
26
- name = 'pyramid_html ' ,
26
+ name = 'pyramid_app ' ,
27
27
version = '0.0' ,
28
- description = 'pyramid-html ' ,
28
+ description = 'pyramid-app ' ,
29
29
long_description = README + '\n \n ' + CHANGES ,
30
30
classifiers = [
31
31
'Programming Language :: Python' ,
46
46
install_requires = requires ,
47
47
entry_points = {
48
48
'paste.app_factory' : [
49
- 'main = pyramid_html :main' ,
49
+ 'main = pyramid_app :main' ,
50
50
],
51
51
},
52
52
)
Original file line number Diff line number Diff line change 4
4
# ##
5
5
6
6
[app:main]
7
- use = egg:pyramid_html
7
+ use = egg:pyramid_app
8
8
9
9
pyramid.reload_templates = false
10
10
pyramid.debug_authorization = false
@@ -26,7 +26,7 @@ listen = localhost:6543
26
26
# ##
27
27
28
28
[loggers]
29
- keys = root, pyramid_html
29
+ keys = root, pyramid_app
30
30
31
31
[handlers]
32
32
keys = console
@@ -38,10 +38,10 @@ keys = generic
38
38
level = INFO
39
39
handlers = console
40
40
41
- [logger_pyramid_html ]
41
+ [logger_pyramid_app ]
42
42
level = DEBUG
43
43
handlers =
44
- qualname = pyramid_html
44
+ qualname = pyramid_app
45
45
46
46
[handler_console]
47
47
class = StreamHandler
File renamed without changes.
Original file line number Diff line number Diff line change 5
5
import pytest
6
6
import webtest
7
7
8
- from pyramid_html import main
8
+ from pyramid_app import main
9
9
10
10
11
11
def pytest_addoption (parser ):
File renamed without changes.
Original file line number Diff line number Diff line change 1
- from pyramid_html .views .default import home , about
2
- from pyramid_html .views .notfound import notfound_view
1
+ from pyramid_app .views .default import home , about
2
+ from pyramid_app .views .notfound import notfound_view
3
3
4
4
5
5
def test_home (app_request ):
6
6
info = home (app_request )
7
7
assert app_request .response .status_int == 200
8
- assert info ['project' ] == 'pyramid-html '
8
+ assert info ['project' ] == 'pyramid-app '
9
9
10
10
11
11
def test_notfound_view (app_request ):
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments