Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Co-authored-by: Bruno Rocha <rochacbruno@users.noreply.github.com>
- Loading branch information
1 parent
df2da01
commit 7bb4e4b
Showing
4 changed files
with
33 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
.PHONY: test clean | ||
|
||
export FLASK_APP=app:create_app | ||
|
||
test: clean | ||
dynaconf init -v test_var | ||
grep '\[development\]' settings.toml | ||
|
||
clean: | ||
rm -rf settings.toml | ||
rm -rf .secrets.toml | ||
rm -rf .gitignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
from __future__ import annotations | ||
|
||
from flask import Blueprint | ||
from flask import Flask | ||
|
||
blueprint = Blueprint("default", __name__) | ||
|
||
|
||
@blueprint.route("/") | ||
def index(): | ||
return "Default route." | ||
|
||
|
||
def create_app(): | ||
app = Flask(__name__) | ||
app.register_blueprint(blueprint) | ||
app.config["ENV"] = "development" | ||
return app |