Skip to content

Commit

Permalink
WOAH! Move "samples" up.
Browse files Browse the repository at this point in the history
  • Loading branch information
csev committed Apr 23, 2019
1 parent 22becbd commit 5726fc1
Show file tree
Hide file tree
Showing 279 changed files with 5 additions and 80 deletions.
66 changes: 2 additions & 64 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,69 +1,7 @@
DJ4E Samples
============

This is a set of Django projects that provide free sample code to
support the www.dj4e.com web site.

You can seem some of the samples at

http://samples.dj4e.com

To set this up, simply check it out into some folder

cd ...wherever...
git clone https://github.com/csev/dj4e-samples.git

There are several subfolders:

* `samples` is a Django project that contains a set of simple sample applications
that demonstrate a single concept per application

* `dj4ecrud` is a Djanog project that contains a complete working
CRUD application with autos and makes

These samples may be updated from time to tims so you might want to get updates
using `git pull`. Also if there are bugs, you are welcome to submit
a Pull Request on github.

All of the documentation material is copyright CC-BY 3.0 and the code is copyright MIT
by whomever wrote the code or documentation. You are welcome to use this in any way you see
fit and paste code from this repo into your applications.

Running Locally
---------------

If you have Django installed on your local computer you can test any of the sample
applications bygoing into the folder and starting the server:
After checkout, run

cd dj4e-samples/samples
cd hello
python3 manage.py runserver

And visit `http://localhost:8000`.

Running on PythonAnywhere
-------------------------

If you are using PythonAnywhere.com to run your Django applications, you
can check all the sample code out as follows:

cd ~
git clone https://github.com/csev/dj4e-samples.git

Then under the web tab, update the config files to point to your new application:

Source code: /home/--your-account--/dj4e-samples/samples
Working Directory: /home/--your-account--/dj4e-samples/samples

Update the lines in your `WGSI configuration file`:

...
path = os.path.expanduser('~/dj4e-samples/samples')
...
os.environ['DJANGO_SETTINGS_MODULE'] = 'samples.settings'

Then `Reload` your application and then visit the site. If the top level folder
insists on redirecting to `/catalog` simply clear your cache.
pip3 install -r requirements.txt

You can edit these files and settings in the Web tab to easily switch between
the various projects in this repository.
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.
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.
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.
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.
File renamed without changes.
4 changes: 2 additions & 2 deletions samples/samples/settings.py → dj4e-samples/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@
'social_django.middleware.SocialAuthExceptionMiddleware', # Add
]

ROOT_URLCONF = 'samples.urls'
ROOT_URLCONF = 'dj4e-samples.urls'

TEMPLATES = [
{
Expand All @@ -105,7 +105,7 @@
},
]

WSGI_APPLICATION = 'samples.wsgi.application'
WSGI_APPLICATION = 'dj4e-samples.wsgi.application'


# Database
Expand Down
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
2 changes: 1 addition & 1 deletion samples/manage.py → manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import sys

if __name__ == "__main__":
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "samples.settings")
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "dj4e-samples.settings")
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
Expand Down
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.
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.
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.
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.
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.
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.
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.
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.
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.
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.
File renamed without changes.
File renamed without changes.
File renamed without changes.
7 changes: 0 additions & 7 deletions samples/README.md

This file was deleted.

6 changes: 0 additions & 6 deletions samples/TODO.md

This file was deleted.

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.
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.
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.
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.
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.
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.
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.
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.
File renamed without changes.
File renamed without changes.

0 comments on commit 5726fc1

Please sign in to comment.