Git Product home page Git Product logo

notes-app-1's Introduction

notes_app

Notes application written in Python 3.8 & KivyMD

application description

  • OS independent
  • Notes can be grouped in separate sections, these sections can be added, renamed or removed
  • Notes storage file can be placed anywhere on the local drive but can also be placed in a DropBox shared folder for example to synchronize notes across devices
  • Full-text or word-based search capability across the current section or all sections
  • Customizable fonts and colors, settings can be persisted
  • Notes text is auto-saved while typing

version history

version date description
0.1.1 12/7/2022 removing item drawer menu highlight, improving diff feature, bugfixes
0.1.0 19/6/2022 initial release

FAQ

  • I need to synchronize my notes file across devices, how do I achieve that?
    • Copy the notes file to the synchronized folder of your choice
    • Click the file icon menu in the app, press choose storage file, locate the file in the synchronized folder and you're set

information for developers

The application design is based on the MVC architecture with the observer notification pattern. The notes are stored in a defined text file where the notes sections are separated by the defined section separator pattern.

The model in the MVC is responsible for storing the metadata of this text file only. When the notes text file content significantly changes or when a different text file for storage is chosen, the view is notified through it's registered observer and displays a info message on the UI.

The app uses difflib library to do the best effort to reasonably "version-control" notes in case the storage file was modified from another instance of the app that is using the same text file for notes storage. This can happen when using a shared DropBox folder for example.

When running the app for the first time, these needed files get auto-generated:

  • file_metadata.json - stores the notes text file metadata like it's file path, size and last updated epoch timestamp
{
    "_file_path": {"value": "some/path/to/my_first_file.txt"}, 
    "_file_size": {"value": 42}, 
    "_last_updated_on": {"value": 1654674166}
}
  • my_first_file.txt - this is the notes text file itself
<section=first>  Your first section. 
Here you can write your notes.
<section=second>  Another section of yours.
  • settings.json - stores settings like fonts, colors for the UI
{
    "font_name": {"value": "RobotoMono-Regular"}, 
    "font_size": {"value": "14.0"}, 
    "background_color": {"value": "black"}, 
    "foreground_color": {"value": "green"}
}

When running the app locally, Pipenv is recommended but general requirements.txt file is also attached.

  • generating dependencies graph using Pydeps
cd notes_app
pip3 install pydeps
pydeps notes_app --max-bacon 2 --cluster --rmprefix notes_app. --exclude-exact notes_app.utils notes_app.view notes_app.model notes_app.controller notes_app.observer

  • running unit tests using Pytest
cd notes_app
pytest

building the application

Windows app build from Windows environment:

  • prerequisites example:
virtualenv venv_notes_app
venv_notes_app\Scripts\activate.bat
(venv_notes_app) python -m pip install --upgrade pip wheel setuptools
(venv_notes_app) python -m pip install kivy docutils pygments pypiwin32 kivy.deps.sdl2 kivy.deps.glew kivy.deps.gstreamer kivy.deps.angle
(venv_notes_app) python -m pip install PyInstaller
(venv_notes_app) cd ..
(venv_notes_app) PyInstaller --name notes notes_app/main.py
ren "notes.spec" "notes_win.spec"
change in the spec file the line datas=[], to datas=[("notes_app\\view\\notes_view.kv", "notes_app\\view\\")],
  • build command example:
(venv_notes_app) PyInstaller c:\notes_app\notes_app\notes_win.spec

Linux app build from Linux environment:

  • prerequisites example:
virtualenv venv_notes_app
source bin/activate
(venv_notes_app) python -m pip install --upgrade pip wheel setuptools
(venv_notes_app) python -m pip install PyInstaller
mv notes.spec notes_linux.spec
change in the spec file the line datas=[], to datas=[("notes_app/view/notes_view.kv", "notes_app/view/")],
  • build command example:
(venv_notes_app) pyinstaller notes_linux.spec

useful links

notes-app-1's People

Contributors

datahappy1 avatar dependabot[bot] avatar pprud avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.