docs, wip
authorShane Jaroch <nutratracker@protonmail.com>
Sun, 29 May 2022 16:19:29 +0000 (12:19 -0400)
committerShane Jaroch <nutratracker@protonmail.com>
Sun, 29 May 2022 16:30:00 +0000 (12:30 -0400)
CHANGELOG.md
Makefile
sql/__init__.py

index 12870f4470ac165f7159448e81ec256a98ca97f6..6b2cb263b7dc524c580245b6980b783bbbf717c4 100644 (file)
@@ -1,63 +1,84 @@
 # Changelog
+
 All notable changes to this project will be documented in this file.
 
 The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
 and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
 
 ## [Unreleased]
+
 ### Changed
-- Replace grams with `msre_id` and `amt` in `food_log` table
+
+-   Replace grams with `msre_id` and `amt` in `food_log` table
 
 ## [0.0.4] - 2021-06-17
+
 ### Added
-- Empty `__init__.py` file to make packagable with `cli` repo (as a `git submodule`)
-- Tables `custom_foods` and respective `cf_dat`
+
+-   Empty `__init__.py` file to make packagable with `cli` repo (as a `git submodule`)
+-   Tables `custom_foods` and respective `cf_dat`
 
 ### Changed
-- Build with `python sql/__init__.py` (removed root-level script `build.py`)
-- Rename pre-populted `meals` table to `meal_name`
+
+-   Build with `python sql/__init__.py` (removed root-level script `build.py`)
+-   Rename pre-populted `meals` table to `meal_name`
 
 ### Fixed
-- Slight bash inconvenience when using `export.sh`
+
+-   Slight bash inconvenience when using `export.sh`
 
 ### Removed
-- `food_costs` table
+
+-   `food_costs` table
 
 ## [0.0.3] - 2021-05-24
+
 ### Added
-- More dummy CSV data (not production ready)
-- `tagname` column to `recipes` table
+
+-   More dummy CSV data (not production ready)
+-   `tagname` column to `recipes` table
 
 ### Changed
-- `date` column uses `INT` type now, instead of `date`
-- Drop `created` and `updated` fields off of `rda` table, add them to `biometrics`
+
+-   `date` column uses `INT` type now, instead of `date`
+-   Drop `created` and `updated` fields off of `rda` table, add them to `biometrics`
 
 ### Removed
-- `last_sync` column (future release? Feature is planned, but not alloted)
-- `guid` parameter from `functions.sql`
+
+-   `last_sync` column (future release? Feature is planned, but not alloted)
+-   `guid` parameter from `functions.sql`
 
 ## [0.0.2] - 2021-05-24
+
 ### Added
+
 `SCRIPT_DIR` in `sql/__init__.py` to help track `cwd`
 
 ### Removed
-- `guid` columns (may return in a future release)
+
+-   `guid` columns (may return in a future release)
 
 ## [0.0.1] - 2021-05-21
+
 ### Added
-- Version table
-- Travis CI configuration file `.travis.yml`
-- `functions.sql` for use in Python client
-- [TODO] Placeholder for initial upgrade script (`sql/upgrade_scripts/0.0.1.sql`)
-- `food_costs` table (lone table, functionality not yet implemented)
+
+-   Version table
+-   Travis CI configuration file `.travis.yml`
+-   `functions.sql` for use in Python client
+-   [TODO] Placeholder for initial upgrade script (`sql/upgrade_scripts/0.0.1.sql`)
+-   `food_costs` table (lone table, functionality not yet implemented)
 
 ### Changed
-- Use Python for import script (`build.py` replaced `import.sql`)
+
+-   Use Python for import script (`build.py` replaced `import.sql`)
 
 ## [0.0.0] - 2020-09-22
+
 ### Added
-- Initial release of table schema design
-- Import script `import.sql` (SQL)
-- Export script `export.sh` (Shell)
-- Rudimentary dummy data in CSV files (e.g. `food_log.csv`, `biometric_log.csv`, `profiles.csv`)
-- Database diagram generated via `docs/sqleton.sh`
+
+-   Initial release of table schema design
+-   Import script `import.sql` (SQL)
+-   Export script `export.sh` (Shell)
+-   Rudimentary dummy data in CSV files
+    (e.g. `food_log.csv`, `biometric_log.csv`, `profiles.csv`)
+-   Database diagram generated via `docs/sqleton.sh`
index 3849140991045aa6958f68c7971926031f94e01e..b4c3296b64e779da141c72ae83c52fa40865028e 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
 .DEFAULT_GOAL := build
 
 clean:
-       find sql/ -name __pycache__ | xargs rm -rf
+       find sql/ -name __pycache__ -o -name .pytest_cache | xargs rm -rf
        rm -f  sql/nt.sqlite
 
 build:
index 64d209a41df0a13af8e458e7849508225ba99ed2..0fe25d8a9a6853742c2f4f23f3bae32b40405959 100755 (executable)
@@ -45,8 +45,8 @@ def build_ntsqlite(verbose=False):
             query = "INSERT INTO {0} VALUES ({1});".format(  # nosec: B608
                 table_name, values
             )
-            print(query)
-            exit()
+            print(query)
+            exit()
             cur.executemany(query, reader)
 
     cur.close()