2013-04-26 17:09:24 +00:00
|
|
|
# Copyright 2005-2008, James Garrison
|
|
|
|
# Copyright 2010, 2012 Bradley M. Kuhn
|
|
|
|
|
|
|
|
# This software's license gives you freedom; you can copy, convey,
|
|
|
|
# propagate, redistribute, modify and/or redistribute modified versions of
|
|
|
|
# this program under the terms of the GNU Affero General Public License
|
|
|
|
# (AGPL) as published by the Free Software Foundation (FSF), either
|
|
|
|
# version 3 of the License, or (at your option) any later version of the
|
|
|
|
# AGPL published by the FSF.
|
|
|
|
#
|
|
|
|
# This program is distributed in the hope that it will be useful, but
|
|
|
|
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero
|
|
|
|
# General Public License for more details.
|
|
|
|
#
|
|
|
|
# You should have received a copy of the GNU Affero General Public License
|
|
|
|
# along with this program in a file in the toplevel directory called
|
|
|
|
# "AGPLv3". If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
2024-04-26 06:06:48 +00:00
|
|
|
from django.conf import settings
|
|
|
|
from django.conf.urls.static import static
|
2021-10-13 10:20:24 +00:00
|
|
|
from django.contrib import admin
|
2024-04-26 06:06:48 +00:00
|
|
|
from django.urls import include, path, re_path
|
2015-03-03 18:40:18 +00:00
|
|
|
|
2024-05-10 01:27:51 +00:00
|
|
|
from . import feeds
|
2023-10-20 07:25:55 +00:00
|
|
|
from .fundgoal import views as fundgoal_views
|
2024-05-10 01:27:51 +00:00
|
|
|
from . import views
|
|
|
|
from conservancy.supporters import views as supporters_views
|
2010-09-26 21:20:05 +00:00
|
|
|
|
2017-11-03 15:47:21 +00:00
|
|
|
urlpatterns = [
|
2024-05-10 01:27:51 +00:00
|
|
|
path('', views.frontpage),
|
2024-03-18 07:24:31 +00:00
|
|
|
path('admin/', admin.site.urls),
|
2024-03-20 05:51:28 +00:00
|
|
|
path('assignment/', include('conservancy.assignment.urls')),
|
|
|
|
path('blog/', include('conservancy.blog.urls')),
|
2024-04-25 05:32:24 +00:00
|
|
|
path('casts/', include('conservancy.podjango.urls')),
|
2024-04-09 12:50:06 +00:00
|
|
|
path('contacts/', include('conservancy.contacts.urls')),
|
2024-03-20 05:51:28 +00:00
|
|
|
path('contractpatch/', include('conservancy.contractpatch.urls')),
|
|
|
|
path('feeds/', feeds.view),
|
2024-03-18 07:24:31 +00:00
|
|
|
path('feeds/blog/', feeds.BlogFeed()),
|
|
|
|
path('feeds/news/', feeds.PressReleaseFeed()),
|
|
|
|
path('feeds/omnibus/', feeds.OmnibusFeed()),
|
2024-03-20 05:51:28 +00:00
|
|
|
path('fossy/', include('conservancy.fossy.urls')),
|
|
|
|
path('fundraiser_data/', fundgoal_views.view),
|
2024-03-18 07:24:31 +00:00
|
|
|
path('news/', include('conservancy.news.urls')),
|
2024-05-10 01:27:51 +00:00
|
|
|
path('sponsors/', supporters_views.sponsors),
|
|
|
|
path('sponsors/index.html', supporters_views.sponsors),
|
2024-05-06 23:45:19 +00:00
|
|
|
path('sustainer/', include('conservancy.supporters.urls')),
|
2024-03-20 05:51:28 +00:00
|
|
|
path('usethesource/', include('conservancy.usethesource.urls')),
|
|
|
|
|
|
|
|
# Directories of templates and files
|
2024-05-10 01:27:51 +00:00
|
|
|
re_path(r'^about/', views.content),
|
|
|
|
re_path(r'^activities/', views.content),
|
|
|
|
re_path(r'^copyleft-compliance/', views.content, {'fundraiser_sought': 'vmware-match-0'}),
|
|
|
|
re_path(r'^donate/', views.content),
|
|
|
|
path('fossy/', views.content),
|
|
|
|
re_path(r'^GiveUpGitHub/', views.content),
|
|
|
|
re_path(r'^learn/', views.content),
|
|
|
|
re_path(r'^npoacct/', views.content, {'fundraiser_sought': 'npoacct'}),
|
|
|
|
re_path(r'^overview/', views.content), # Unused?
|
|
|
|
re_path(r'^press/', views.content),
|
|
|
|
re_path(r'^privacy-policy/', views.content),
|
|
|
|
re_path(r'^projects/', views.content),
|
|
|
|
re_path(r'^sustainer/', views.content),
|
2017-11-03 15:47:21 +00:00
|
|
|
]
|
2024-04-26 06:06:48 +00:00
|
|
|
|
|
|
|
# Serve uploaded media. Works only when DEBUG == True. Using '/media/'
|
|
|
|
# explicitly here because MEDIA_URL include scheme/host/port, which would
|
|
|
|
# otherwise break debug media serving.
|
|
|
|
# https://docs.djangoproject.com/en/4.0/howto/static-files/#serving-files-uploaded-by-a-user-during-development
|
|
|
|
urlpatterns += static('/media/', document_root=settings.MEDIA_ROOT)
|