Skip to content

Generate View's Website #14

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

Merged
merged 4 commits into from
Dec 18, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ covhtml/
__pycache__/

env/
demo/db.sqlite3
dist/
djangorestframeworkdocs.egg-info/

demo/env/
demo/db.sqlite3
rest_framework_docs/static/node_modules/
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@ include LICENSE

recursive-include rest_framework_docs/static *.js *.css *.less *.png *.eot *.svg *.ttf *.woff
recursive-include rest_framework_docs/templates *.html

recursive-exclude rest_framework_docs/static/node_modules *.*
recursive-exclude * __pycache__
recursive-exclude * *.py[co]
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Document Web APIs made with Django Rest Framework.
### Supports

- Python (2.7, 3.3, 3.4, 3.5)
- Django (1.7, 1.8, 1.9)
- Django (1.8, 1.9)
- Django Rest Framework (3+)


Expand Down
11 changes: 9 additions & 2 deletions demo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,25 @@ A demo project to get you started with DRF docs development.


### Installation
From the route of the repository:

# Create the virtual environment
pyvenv env

# Install requirements
env/bin/pip install -r requirements.txt

# Activate the environment
source env/bin/activate

# Cd Into the demo
cd demo/

# Install Django Rest Framework Docs
env/bin/pip install -e ../
pip install -e ../

# Run the project
env/bin/python manage.py runserver
python manage.py runserver

**Note**: You **do not** need a database or to run `migrate`.

Expand Down
2 changes: 0 additions & 2 deletions demo/requirements.txt

This file was deleted.

8 changes: 8 additions & 0 deletions rest_framework_docs/static/css/style.css

Large diffs are not rendered by default.

Binary file added rest_framework_docs/static/fonts/FontAwesome.otf
Binary file not shown.
Binary file not shown.
655 changes: 655 additions & 0 deletions rest_framework_docs/static/fonts/fontawesome-webfont.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
288 changes: 288 additions & 0 deletions rest_framework_docs/static/fonts/glyphicons-halflings-regular.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
5 changes: 5 additions & 0 deletions rest_framework_docs/static/less/style.less
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
@import "node_modules/bootstrap/less/bootstrap";
@import "node_modules/bootswatch/flatly/variables.less";
@import "node_modules/font-awesome/less/font-awesome.less";
@import url(http://fonts.googleapis.com/css?family=ABeeZee);

/* @group Colours */

@ThemeAlt: #c9c9c9;
Expand Down
42 changes: 42 additions & 0 deletions rest_framework_docs/static/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"name": "django-rest-framework-docs",
"version": "0.0.1",
"description": "Document Web APIs made with Django Rest Framework",
"main": "index.js",
"scripts": {
"build-font-awesome": "cp -r node_modules/font-awesome/fonts .",
"build-bootstrap-fonts": "cp -r node_modules/bootstrap/fonts .",
"build-less": "lessc --clean-css less/style.less css/style.css",
"watch-less": "watch 'npm run build-less' less/",
"build": "npm run build-font-awesome && npm run build-bootstrap-fonts && npm run build-less",
"start": "npm run build && npm run watch-less",
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ekonstantinidis/django-rest-framework-docs.git"
},
"keywords": [
"django",
"rest",
"framework",
"docs",
"jekyll"
],
"author": "Emmanouil Konstantinidis",
"license": "SEE LICENSE IN LICENSE",
"bugs": {
"url": "https://github.com/ekonstantinidis/django-rest-framework-docs/issues"
},
"homepage": "https://www.drfdocs.com/",
"dependencies": {
"bootstrap": "=3.3.6",
"bootswatch": "=3.3.6",
"font-awesome": "=4.5.0"
},
"devDependencies": {
"less": "=2.5.3",
"less-plugin-clean-css": "=1.5.1",
"watch": "=0.16.0"
}
}
11 changes: 2 additions & 9 deletions rest_framework_docs/templates/rest_framework_docs/base.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% load staticfiles %}
{% load static from staticfiles %}

<!DOCTYPE html>
<html>
Expand All @@ -9,15 +9,8 @@

<title>{% block title %}DRF Docs{% endblock %}</title>

<!-- Bootstrap & Flatly -->
<link href="https://maxcdn.bootstrapcdn.com/bootswatch/3.3.5/flatly/bootstrap.min.css" rel="stylesheet">
<!-- Font Awesome -->
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css" rel="stylesheet">
<!-- Custom Style -->
<link rel="stylesheet/less" type="text/css" href="{% static "less/style.less" %}" />

<!-- LESS CSS -->
<script src="//cdnjs.cloudflare.com/ajax/libs/less.js/2.5.3/less.min.js"></script>
<link rel="stylesheet" href="{% static "css/style.css" %}">
</head>

<body>
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.5'
],
)