-
-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Submodules, file subsets and chats&messages (#50)
- Loading branch information
Showing
17 changed files
with
994 additions
and
287 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[project] | ||
name = "claudesync" | ||
version = "0.5.1" | ||
version = "0.5.2" | ||
authors = [ | ||
{name = "Jahziah Wagner", email = "[email protected]"}, | ||
] | ||
|
@@ -14,11 +14,14 @@ classifiers = [ | |
"Operating System :: OS Independent", | ||
] | ||
dependencies = [ | ||
"Click>=8.1.7", | ||
"pathspec>=0.12.1", | ||
"crontab>=1.0.1", | ||
"click_completion>=0.5.2", | ||
"tqdm>=4.66.4", | ||
"click==8.1.7", | ||
"click_completion==0.5.2", | ||
"pathspec==0.12.1", | ||
"pytest==8.3.2", | ||
"python_crontab==3.2.0", | ||
"setuptools==73.0.1", | ||
"sseclient_py==1.8.0", | ||
"tqdm==4.66.5", | ||
] | ||
keywords = [ | ||
"sync", | ||
|
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 |
---|---|---|
@@ -1,6 +1,9 @@ | ||
Click>=8.1.7 | ||
pathspec>=0.12.1 | ||
crontab>=1.0.1 | ||
click>=8.1.7 | ||
click_completion>=0.5.2 | ||
tqdm>=4.66.4 | ||
pathspec>=0.12.1 | ||
pytest>=8.3.2 | ||
python_crontab>=3.2.0 | ||
setuptools>=73.0.1 | ||
sseclient_py>=1.8.0 | ||
tqdm>=4.66.5 | ||
pytest-cov>=5.0.0 |
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,61 @@ | ||
import click | ||
from ..utils import handle_errors | ||
|
||
|
||
@click.group() | ||
def category(): | ||
"""Manage file categories.""" | ||
pass | ||
|
||
|
||
@category.command() | ||
@click.argument("name") | ||
@click.option("--description", required=True, help="Description of the category") | ||
@click.option( | ||
"--patterns", required=True, multiple=True, help="File patterns for the category" | ||
) | ||
@click.pass_obj | ||
@handle_errors | ||
def add(config, name, description, patterns): | ||
"""Add a new file category.""" | ||
config.add_file_category(name, description, list(patterns)) | ||
click.echo(f"File category '{name}' added successfully.") | ||
|
||
|
||
@category.command() | ||
@click.argument("name") | ||
@click.pass_obj | ||
@handle_errors | ||
def remove(config, name): | ||
"""Remove a file category.""" | ||
config.remove_file_category(name) | ||
click.echo(f"File category '{name}' removed successfully.") | ||
|
||
|
||
@category.command() | ||
@click.argument("name") | ||
@click.option("--description", help="New description for the category") | ||
@click.option("--patterns", multiple=True, help="New file patterns for the category") | ||
@click.pass_obj | ||
@handle_errors | ||
def update(config, name, description, patterns): | ||
"""Update an existing file category.""" | ||
config.update_file_category(name, description, list(patterns) if patterns else None) | ||
click.echo(f"File category '{name}' updated successfully.") | ||
|
||
|
||
@category.command() | ||
@click.pass_obj | ||
@handle_errors | ||
def ls(config): | ||
"""List all file categories.""" | ||
categories = config.get("file_categories", {}) | ||
if not categories: | ||
click.echo("No file categories defined.") | ||
else: | ||
for name, data in categories.items(): | ||
click.echo(f"\nCategory: {name}") | ||
click.echo(f"Description: {data['description']}") | ||
click.echo("Patterns:") | ||
for pattern in data["patterns"]: | ||
click.echo(f" - {pattern}") |
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
Oops, something went wrong.