mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-05-05 12:41:49 +02:00
Merge 5e0fb23218
into cdf903383a
This commit is contained in:
commit
6e709b6c64
4 changed files with 22 additions and 10 deletions
11
Makefile
11
Makefile
|
@ -1,6 +1,6 @@
|
||||||
VIRTUALENV = virtualenv --python=python3
|
VIRTUALENV = virtualenv --python=python3
|
||||||
SPHINX_BUILDDIR = docs/_build
|
SPHINX_BUILDDIR = docs/_build
|
||||||
VENV := $(shell echo $${VIRTUAL_ENV-.venv})
|
VENV := $(shell realpath $${VIRTUAL_ENV-.venv})
|
||||||
PYTHON = $(VENV)/bin/python3
|
PYTHON = $(VENV)/bin/python3
|
||||||
DEV_STAMP = $(VENV)/.dev_env_installed.stamp
|
DEV_STAMP = $(VENV)/.dev_env_installed.stamp
|
||||||
DOC_STAMP = $(VENV)/.doc_env_installed.stamp
|
DOC_STAMP = $(VENV)/.doc_env_installed.stamp
|
||||||
|
@ -8,7 +8,7 @@ INSTALL_STAMP = $(VENV)/.install.stamp
|
||||||
TEMPDIR := $(shell mktemp -d)
|
TEMPDIR := $(shell mktemp -d)
|
||||||
|
|
||||||
all: install
|
all: install
|
||||||
install: $(INSTALL_STAMP)
|
install: virtualenv $(INSTALL_STAMP)
|
||||||
$(INSTALL_STAMP):
|
$(INSTALL_STAMP):
|
||||||
$(VENV)/bin/pip install -U pip
|
$(VENV)/bin/pip install -U pip
|
||||||
$(VENV)/bin/pip install -r requirements.txt
|
$(VENV)/bin/pip install -r requirements.txt
|
||||||
|
@ -23,8 +23,8 @@ $(DEV_STAMP): $(PYTHON) dev-requirements.txt
|
||||||
$(VENV)/bin/pip install -Ur dev-requirements.txt
|
$(VENV)/bin/pip install -Ur dev-requirements.txt
|
||||||
touch $(DEV_STAMP)
|
touch $(DEV_STAMP)
|
||||||
|
|
||||||
serve: $(INSTALL_STAMP)
|
serve: install
|
||||||
cd budget; ../$(PYTHON) run.py
|
cd budget; $(PYTHON) run.py
|
||||||
|
|
||||||
test: $(DEV_STAMP)
|
test: $(DEV_STAMP)
|
||||||
$(VENV)/bin/tox
|
$(VENV)/bin/tox
|
||||||
|
@ -37,3 +37,6 @@ build-requirements:
|
||||||
$(TEMPDIR)/bin/pip install -U pip
|
$(TEMPDIR)/bin/pip install -U pip
|
||||||
$(TEMPDIR)/bin/pip install -Ue "."
|
$(TEMPDIR)/bin/pip install -Ue "."
|
||||||
$(TEMPDIR)/bin/pip freeze | grep -v -- '-e' > requirements.txt
|
$(TEMPDIR)/bin/pip freeze | grep -v -- '-e' > requirements.txt
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf .venv
|
||||||
|
|
|
@ -16,10 +16,15 @@ LICENSE for more details).
|
||||||
Make it run!
|
Make it run!
|
||||||
============
|
============
|
||||||
|
|
||||||
To make it run, you just have to do use the serve command::
|
On Linux, with a `Python 3 <https://www.python.org/>` environment,
|
||||||
|
`pip <https://pypi.python.org/pypi/pip/>` and
|
||||||
|
`virtualenv <https://pypi.python.org/pypi/virtualenv>` installed,
|
||||||
|
you just have to do use the serve command::
|
||||||
|
|
||||||
$ make serve
|
$ make serve
|
||||||
|
|
||||||
|
This will run a Flask app available at `http://localhost:5000`.
|
||||||
|
|
||||||
It is also better to actually turn the debugging mode on when you're
|
It is also better to actually turn the debugging mode on when you're
|
||||||
developing. You can create a `settings.py` file in the `budget` directory, with
|
developing. You can create a `settings.py` file in the `budget` directory, with
|
||||||
the following content::
|
the following content::
|
||||||
|
|
1
budget/static/css/bootstrap.min.css.map
Normal file
1
budget/static/css/bootstrap.min.css.map
Normal file
File diff suppressed because one or more lines are too long
|
@ -34,10 +34,15 @@
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
<nav class="navbar navbar-toggleable-md navbar-inverse fixed-top bg-inverse">
|
||||||
|
<button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarsExampleDefault" aria-controls="navbarsExampleDefault" aria-expanded="false" aria-label="Toggle navigation">
|
||||||
|
<span class="navbar-toggler-icon"></span>
|
||||||
|
</button>
|
||||||
|
|
||||||
<nav class="navbar navbar-toggleable-md navbar fixed-top navbar-inverse bg-inverse">
|
<a class="navbar-brand" href="#">#! money?</a>
|
||||||
<h1 class="col-2"><a class="navbar-brand" href="{{ url_for(".home") }}">#! money?</a></h1>
|
|
||||||
<ul class="navbar-nav col-5 offset-md-1">
|
<div class="collapse navbar-collapse" id="navbarsExampleDefault">
|
||||||
|
<ul class="navbar-nav col-5 offset-md-1">
|
||||||
{% if g.project %}
|
{% if g.project %}
|
||||||
{% block navbar %}
|
{% block navbar %}
|
||||||
<li class="nav-item{% if current_view == 'list_bills' %} active{% endif %}"><a class="nav-link" href="{{ url_for(".list_bills") }}">{{ _("Bills") }}</a></li>
|
<li class="nav-item{% if current_view == 'list_bills' %} active{% endif %}"><a class="nav-link" href="{{ url_for(".list_bills") }}">{{ _("Bills") }}</a></li>
|
||||||
|
@ -66,8 +71,6 @@
|
||||||
<li class="nav-item{% if g.lang == "fr" %} active{% endif %}"><a class="nav-link" href="{{ url_for(".change_lang", lang="fr") }}">fr</a></li>
|
<li class="nav-item{% if g.lang == "fr" %} active{% endif %}"><a class="nav-link" href="{{ url_for(".change_lang", lang="fr") }}">fr</a></li>
|
||||||
<li class="nav-item{% if g.lang == "en" %} active{% endif %}"><a class="nav-link" href="{{ url_for(".change_lang", lang="en") }}">en</a></li>
|
<li class="nav-item{% if g.lang == "en" %} active{% endif %}"><a class="nav-link" href="{{ url_for(".change_lang", lang="en") }}">en</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
|
Loading…
Reference in a new issue