Skip to content

Commit e861db7

Browse files
authored
Merge pull request #36 from UBC-MDS/develop
Develop -> Main / Completion of Milestone 2
2 parents f7ee4a1 + eebf226 commit e861db7

File tree

15 files changed

+2384
-290
lines changed

15 files changed

+2384
-290
lines changed

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,3 +243,9 @@ cython_debug/
243243

244244
# Hatch-VCS
245245
_version.py
246+
247+
# Coverage file from pytest
248+
.coverage
249+
250+
# Development file from copier
251+
DEVELOPMENT.md

CHANGELOG.md

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,32 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8-
## [Unreleased]
8+
## [Unreleased]
99

10-
- Upcoming features and fixes
10+
- Upcoming features and fixes:
11+
- CI integration via GitHub Workflows
12+
- Publish on PyPi
1113

12-
## [0.1.0] - (1979-01-01)
14+
## [0.0.2] - (2026-01-17)
1315

14-
- First release
16+
### Added
17+
18+
- Added pandas dependency to pyproject.toml
19+
- `suggest_break` function that recommends break activities based on work duration and preferences (break type, duration, location, energy level)
20+
- `get_affirmation` function that returns motivational affirmations based on energy level and task type
21+
- `plan_pomodoro()` implementation for generating Pomodoro-style work/break schedules.
22+
- `prioritize_tasks()` function for ranking tasks by priority (either by importance or deadline)
23+
- Comprehensive test suite for `suggest_break`, `get_affirmation`, `plan_pomodoro`
24+
- Added `Testing` portion to the README.md
25+
- Added a brief description of the package in `src/deepwork/__init__.py`
26+
27+
### Changed
28+
29+
- Updated all docstring to be more comprehensive and include examples of usage.
30+
- Added `--cov-branch` flag under the [tool.hatch.envs.test.scripts] matrix in the `pyproject.toml` file
31+
32+
## [0.0.1] - (2026-01-10)
33+
34+
- First release:
35+
- Create project structure for the software package
36+
- Write function specifications and documentation

DEVELOPMENT.md

Lines changed: 0 additions & 229 deletions
This file was deleted.

README.md

Lines changed: 29 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
| | |
44
|------------------------------------|------------------------------------|
5-
| Package | [![PyPI Version](https://img.shields.io/badge/PyPI-v0.0.0-lightgrey.svg)](#) [![Python Versions](https://img.shields.io/badge/Python-3.8%2B-lightgrey.svg)](#) |
5+
| Package | [![PyPI Version](https://img.shields.io/badge/PyPI-v0.1.0-lightgrey.svg)](#) [![Python Versions](https://img.shields.io/badge/Python-3.10%2B-lightgrey.svg)](#) |
66
| Meta | [![Code of Conduct](https://img.shields.io/badge/Contributor%20Covenant-v2.0%20adopted-ff69b4.svg)](CODE_OF_CONDUCT.md) |
77

88
`deepwork` is a Python package for developer productivity that helps developers stay focused and energized throughout the workday. `deepwork` provides tools to plan focus (pomodoro) sessions, prioritize tasks, take effective breaks, and stay motivated with personalized affirmations. The perfect package for developers looking to optimize their workflow.
99

1010
## Get Started
11-
11+
> To install the latest release (latest tag) from GitHub, run the following:
1212
``` bash
13-
$ pip install deepwork
13+
$ pip install git+https://github.com/UBC-MDS/deepwork@main
1414
```
1515

1616
### Functions
@@ -31,12 +31,17 @@ This package contains four main functions:
3131

3232
`deepwork` requires the following libraries:
3333

34+
- **Python 3.10+**: Required runtime environment.
3435
- **Pandas**: Used for data manipulation and the structured table display of schedules and tasks.
36+
- **pip**: Used for package installation.
3537

3638
## Usage
3739

3840
``` python
39-
from deepwork import get_affirmation, plan_pomodoro, prioritize_tasks, suggest_break
41+
from deepwork.affirmation import get_affirmation
42+
from deepwork.pomodoro import plan_pomodoro
43+
from deepwork.prioritize import prioritize_tasks
44+
from deepwork.breaks import suggest_break
4045

4146
# Get a motivational affirmation
4247
affirmation = get_affirmation(name="Alice", mood="stressed", energy=4)
@@ -59,6 +64,26 @@ activity = suggest_break(minutes_worked=90, energy_level=4, break_type="active")
5964
print(activity['name'], "-", activity['description'])
6065
```
6166

67+
## Testing
68+
69+
To run the tests for this package, clone the repository and install it with the test dependencies:
70+
71+
1. Clone the repository:
72+
``` bash
73+
$ git clone https://github.com/UBC-MDS/deepwork
74+
```
75+
76+
2. Install the package with test dependencies:
77+
```bash
78+
$ cd path/to/deepwork
79+
$ pip install -e ".[tests]"
80+
```
81+
82+
3. Run tests accordingly:
83+
```bash
84+
$ pytest tests/ -v --cov=deepwork --cov-branch --cov-report=term-missing # shows a verbose output of tests
85+
```
86+
6287
## Python Ecosystem
6388

6489
`deepwork` combines productivity and wellness features into a single cohesive library. While there are separate packages for individual features like [tomato-timer](https://pypi.org/project/tomato-timer/) for Pomodoro timing and various task management libraries, `deepwork` uniquely integrates focus session planning, task prioritization, break suggestions, and motivational affirmations into one package, specifically designed for developers. This holistic approach helps developers maintain both productivity and well-being without needing multiple tools.

pyproject.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ classifiers = [
3636
# TODO: add keywords
3737
keywords = []
3838
# TODO: add dependencies
39-
dependencies = []
39+
dependencies = [
40+
"pandas"
41+
]
4042

4143
[project.urls]
4244
Homepage = "https://github.com/UBC-MDS/deepwork"
@@ -153,7 +155,7 @@ features = [
153155
python = ["3.10", "3.11", "3.12", "3.13"]
154156

155157
[tool.hatch.envs.test.scripts]
156-
run = "pytest {args:--cov=deepwork --cov-report=term-missing --cov-report=xml}"
158+
run = "pytest {args:--cov=deepwork --cov-branch --cov-report=term-missing --cov-report=xml}"
157159

158160
#--------------- Build and preview your documentation ---------------#
159161

src/deepwork/__init__.py

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,14 @@
2222
# SOFTWARE.
2323

2424
"""
25-
Add a docstring here for the init module.
25+
deepwork: A Python package for developer productivity.
2626
27-
This might include a very brief description of the package,
28-
its purpose, and any important notes.
27+
This package helps engineers optimize their workflow by providing tools to:
28+
- Plan focus sessions using Pomodoro and other time-blocking techniques
29+
- Prioritize tasks using weighted scoring or deadline-based methods
30+
- Take effective breaks with activity suggestions based on energy levels
31+
- Stay motivated with personalized developer-focused affirmations
32+
33+
Designed for engineers looking to maintain focus, manage energy,
34+
and sustain productivity throughout the workday.
2935
"""

0 commit comments

Comments
 (0)