simple-vcs 1.1.0__tar.gz → 1.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: simple-vcs
3
- Version: 1.1.0
4
- Summary: A simple version control system with unique features for easy version management
3
+ Version: 1.3.0
4
+ Summary: A beautiful and simple version control system with a stunning terminal interface
5
5
  Home-page: https://github.com/muhammadsufiyanbaig/simple_vcs
6
6
  Author: Muhammad Sufiyan Baig
7
7
  Author-email: Muhammad Sufiyan Baig <send.sufiyan@gmail.com>
@@ -34,6 +34,7 @@ Requires-Python: >=3.7
34
34
  Description-Content-Type: text/markdown
35
35
  License-File: LICENSE
36
36
  Requires-Dist: click>=7.0
37
+ Requires-Dist: rich>=10.0.0
37
38
  Dynamic: author
38
39
  Dynamic: home-page
39
40
  Dynamic: license-file
@@ -41,7 +42,16 @@ Dynamic: requires-python
41
42
 
42
43
  # SimpleVCS
43
44
 
44
- A simple version control system written in Python that provides basic VCS functionality similar to Git.
45
+ A simple version control system written in Python that provides basic VCS functionality similar to Git - now with a **beautiful modern terminal interface**!
46
+
47
+ ## ✨ New in Version 1.3.0
48
+
49
+ **Enhanced Visual Experience** - SimpleVCS now features an even more stunning terminal interface:
50
+ - 🎨 **Enhanced Init** - Beautiful header, tree structure, and quick start guide
51
+ - 📜 **Gorgeous Log** - Double-bordered tables with highlighted current commit and legend
52
+ - 💡 **Rich Help** - Custom help interface with examples and organized commands
53
+ - 🌈 **Professional Design** - Centered headers, better spacing, and visual hierarchy
54
+ - ⭐ **Better UX** - Empty state messages, statistics, and helpful tips throughout
45
55
 
46
56
  ## Features
47
57
 
@@ -240,6 +250,7 @@ When initialized, SimpleVCS creates a `.svcs` directory containing:
240
250
 
241
251
  - Python 3.7 or higher
242
252
  - click>=7.0 (for CLI functionality)
253
+ - rich>=10.0.0 (for beautiful terminal interface)
243
254
 
244
255
  ## Development
245
256
 
@@ -317,6 +328,26 @@ Project Link: [https://github.com/muhammadsufiyanbaig/simple_vcs](https://github
317
328
 
318
329
  ## Changelog
319
330
 
331
+ ### Version 1.3.0
332
+ - **Enhanced Init Command**: Beautiful header, tree visualization, and quick start guide
333
+ - **Gorgeous Log Display**: Double-bordered tables with current commit highlighting
334
+ - **Custom Help Interface**: Rich-formatted help with organized commands and examples
335
+ - **Better Visual Hierarchy**: Centered headers, improved spacing, and alignment
336
+ - **Enhanced Empty States**: Helpful messages when no commits exist
337
+ - **Statistics Display**: Show total commits, current commit, and filters in log
338
+ - **Legend Support**: Clear explanations of symbols and formatting
339
+ - **Professional Polish**: Refined colors, borders, and overall presentation
340
+
341
+ ### Version 1.2.0
342
+ - **Beautiful Terminal Interface**: Complete visual overhaul with Rich library
343
+ - **Colored Output**: Green for success, yellow for warnings, red for errors
344
+ - **Elegant Tables**: Commit history, status, and diffs in formatted tables
345
+ - **Styled Panels**: Information displayed in bordered panels with rounded corners
346
+ - **Enhanced Commands**: All commands now have beautiful, professional output
347
+ - **Better UX**: Clear visual hierarchy and consistent formatting
348
+ - **Windows Compatible**: No problematic Unicode characters
349
+ - **Enhanced Help**: Detailed descriptions and examples for all commands
350
+
320
351
  ### Version 1.1.0
321
352
  - Added quick revert functionality to go back to any commit instantly
322
353
  - Added snapshot creation and restoration features
@@ -1,6 +1,15 @@
1
1
  # SimpleVCS
2
2
 
3
- A simple version control system written in Python that provides basic VCS functionality similar to Git.
3
+ A simple version control system written in Python that provides basic VCS functionality similar to Git - now with a **beautiful modern terminal interface**!
4
+
5
+ ## ✨ New in Version 1.3.0
6
+
7
+ **Enhanced Visual Experience** - SimpleVCS now features an even more stunning terminal interface:
8
+ - 🎨 **Enhanced Init** - Beautiful header, tree structure, and quick start guide
9
+ - 📜 **Gorgeous Log** - Double-bordered tables with highlighted current commit and legend
10
+ - 💡 **Rich Help** - Custom help interface with examples and organized commands
11
+ - 🌈 **Professional Design** - Centered headers, better spacing, and visual hierarchy
12
+ - ⭐ **Better UX** - Empty state messages, statistics, and helpful tips throughout
4
13
 
5
14
  ## Features
6
15
 
@@ -199,6 +208,7 @@ When initialized, SimpleVCS creates a `.svcs` directory containing:
199
208
 
200
209
  - Python 3.7 or higher
201
210
  - click>=7.0 (for CLI functionality)
211
+ - rich>=10.0.0 (for beautiful terminal interface)
202
212
 
203
213
  ## Development
204
214
 
@@ -276,6 +286,26 @@ Project Link: [https://github.com/muhammadsufiyanbaig/simple_vcs](https://github
276
286
 
277
287
  ## Changelog
278
288
 
289
+ ### Version 1.3.0
290
+ - **Enhanced Init Command**: Beautiful header, tree visualization, and quick start guide
291
+ - **Gorgeous Log Display**: Double-bordered tables with current commit highlighting
292
+ - **Custom Help Interface**: Rich-formatted help with organized commands and examples
293
+ - **Better Visual Hierarchy**: Centered headers, improved spacing, and alignment
294
+ - **Enhanced Empty States**: Helpful messages when no commits exist
295
+ - **Statistics Display**: Show total commits, current commit, and filters in log
296
+ - **Legend Support**: Clear explanations of symbols and formatting
297
+ - **Professional Polish**: Refined colors, borders, and overall presentation
298
+
299
+ ### Version 1.2.0
300
+ - **Beautiful Terminal Interface**: Complete visual overhaul with Rich library
301
+ - **Colored Output**: Green for success, yellow for warnings, red for errors
302
+ - **Elegant Tables**: Commit history, status, and diffs in formatted tables
303
+ - **Styled Panels**: Information displayed in bordered panels with rounded corners
304
+ - **Enhanced Commands**: All commands now have beautiful, professional output
305
+ - **Better UX**: Clear visual hierarchy and consistent formatting
306
+ - **Windows Compatible**: No problematic Unicode characters
307
+ - **Enhanced Help**: Detailed descriptions and examples for all commands
308
+
279
309
  ### Version 1.1.0
280
310
  - Added quick revert functionality to go back to any commit instantly
281
311
  - Added snapshot creation and restoration features
@@ -4,15 +4,16 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "simple-vcs"
7
- version = "1.1.0"
8
- description = "A simple version control system with unique features for easy version management"
7
+ version = "1.3.0"
8
+ description = "A beautiful and simple version control system with a stunning terminal interface"
9
9
  authors = [
10
10
  { name = "Muhammad Sufiyan Baig", email = "send.sufiyan@gmail.com" }
11
11
  ]
12
12
  readme = "README.md"
13
13
  requires-python = ">=3.7"
14
14
  dependencies = [
15
- "click>=7.0"
15
+ "click>=7.0",
16
+ "rich>=10.0.0"
16
17
  ]
17
18
  license = { file = "LICENSE" }
18
19
  keywords = ["version-control", "vcs", "simple-vcs", "backup", "snapshot"]
@@ -5,10 +5,10 @@ with open("README.md", "r", encoding="utf-8") as fh:
5
5
 
6
6
  setup(
7
7
  name="simple-vcs",
8
- version="1.1.0",
8
+ version="1.3.0",
9
9
  author="Muhammad Sufiyan Baig",
10
10
  author_email="send.sufiyan@gmail.com",
11
- description="A simple version control system with unique features for easy version management",
11
+ description="A beautiful and simple version control system with a stunning terminal interface",
12
12
  long_description=long_description,
13
13
  long_description_content_type="text/markdown",
14
14
  url="https://github.com/muhammadsufiyanbaig/simple_vcs",
@@ -29,6 +29,7 @@ setup(
29
29
  python_requires=">=3.7",
30
30
  install_requires=[
31
31
  "click>=7.0",
32
+ "rich>=10.0.0",
32
33
  ],
33
34
  entry_points={
34
35
  "console_scripts": [
@@ -0,0 +1,222 @@
1
+ import click
2
+ from .core import SimpleVCS
3
+ from rich.console import Console
4
+ from rich.panel import Panel
5
+ from rich.text import Text
6
+ from rich import box
7
+ from rich.columns import Columns
8
+
9
+ console = Console()
10
+
11
+ class RichGroup(click.Group):
12
+ """Custom Click Group that adds Rich formatting to help output"""
13
+
14
+ def format_help(self, ctx, formatter):
15
+ """Override help formatting with Rich output"""
16
+ console = Console()
17
+
18
+ # Beautiful header
19
+ console.print()
20
+ title = Text("SimpleVCS", style="bold cyan", justify="center")
21
+ subtitle = Text("A Beautiful Version Control System", style="dim", justify="center")
22
+ console.print(title)
23
+ console.print(subtitle)
24
+ console.print()
25
+
26
+ # Description panel
27
+ description = Panel(
28
+ "[white]A lightweight, elegant version control system with a modern terminal interface.\n"
29
+ "Track your files, manage versions, and keep your project history organized.[/white]",
30
+ title="[bold cyan]About[/bold cyan]",
31
+ border_style="cyan",
32
+ box=box.ROUNDED,
33
+ padding=(0, 2)
34
+ )
35
+ console.print(description)
36
+ console.print()
37
+
38
+ # Commands section
39
+ console.print("[bold white]Available Commands:[/bold white]")
40
+ console.print()
41
+
42
+ commands_info = [
43
+ ("init", "Initialize a new repository", "cyan"),
44
+ ("add", "Add files to staging area", "green"),
45
+ ("commit", "Create a new commit", "green"),
46
+ ("status", "Show repository status", "yellow"),
47
+ ("log", "View commit history", "blue"),
48
+ ("diff", "Compare commits", "magenta"),
49
+ ("revert", "Revert to previous commit", "red"),
50
+ ("snapshot", "Create backup snapshot", "cyan"),
51
+ ("restore", "Restore from snapshot", "cyan"),
52
+ ("compress", "Optimize storage", "yellow"),
53
+ ]
54
+
55
+ for cmd_name, cmd_desc, color in commands_info:
56
+ console.print(f" [{color}]{cmd_name:12}[/{color}] [dim]{cmd_desc}[/dim]")
57
+
58
+ console.print()
59
+
60
+ # Usage examples
61
+ examples = Panel(
62
+ "[bold]Quick Start:[/bold]\n"
63
+ "[cyan]$[/cyan] svcs init [dim]# Create repository[/dim]\n"
64
+ "[cyan]$[/cyan] svcs add file.txt [dim]# Stage files[/dim]\n"
65
+ "[cyan]$[/cyan] svcs commit -m \"message\" [dim]# Save changes[/dim]\n"
66
+ "[cyan]$[/cyan] svcs log [dim]# View history[/dim]\n\n"
67
+ "[bold]Get Help:[/bold]\n"
68
+ "[cyan]$[/cyan] svcs [yellow]<command>[/yellow] --help [dim]# Help for specific command[/dim]",
69
+ title="[bold green]Examples[/bold green]",
70
+ border_style="green",
71
+ box=box.ROUNDED,
72
+ padding=(0, 2)
73
+ )
74
+ console.print(examples)
75
+ console.print()
76
+
77
+ # Footer
78
+ console.print(
79
+ "[dim]Version 1.2.0 | "
80
+ "More info: [/dim][cyan]https://github.com/muhammadsufiyanbaig/simple_vcs[/cyan]"
81
+ )
82
+ console.print()
83
+
84
+ # Prevent Click from outputting its own help
85
+ ctx.resilient_parsing = True
86
+
87
+ @click.group(cls=RichGroup)
88
+ @click.version_option(version="1.3.0", prog_name="SimpleVCS")
89
+ def main():
90
+ """SimpleVCS - A beautiful and simple version control system"""
91
+ pass
92
+
93
+ @main.command()
94
+ @click.option('--path', default='.', help='Path where repository will be created')
95
+ def init(path):
96
+ """Initialize a new SimpleVCS repository
97
+
98
+ Creates a new .svcs directory with all necessary files for version control.
99
+
100
+ Example: svcs init --path ./my-project
101
+ """
102
+ vcs = SimpleVCS(path)
103
+ vcs.init_repo()
104
+
105
+ @main.command()
106
+ @click.argument('files', nargs=-1, required=True)
107
+ def add(files):
108
+ """Add files to the staging area
109
+
110
+ Stage files to be included in the next commit. You can add multiple files at once.
111
+
112
+ Example: svcs add file1.txt file2.py
113
+ """
114
+ vcs = SimpleVCS()
115
+ for file in files:
116
+ vcs.add_file(file)
117
+
118
+ @main.command()
119
+ @click.option('-m', '--message', help='Commit message describing the changes')
120
+ def commit(message):
121
+ """Commit staged changes to the repository
122
+
123
+ Creates a new commit with all staged files. If no message is provided,
124
+ an automatic timestamp-based message will be generated.
125
+
126
+ Example: svcs commit -m "Add new feature"
127
+ """
128
+ vcs = SimpleVCS()
129
+ vcs.commit(message)
130
+
131
+ @main.command()
132
+ @click.option('--c1', type=int, help='First commit ID (defaults to second-last commit)')
133
+ @click.option('--c2', type=int, help='Second commit ID (defaults to last commit)')
134
+ def diff(c1, c2):
135
+ """Show differences between commits
136
+
137
+ Compare files between two commits to see what changed. Without arguments,
138
+ compares the last two commits.
139
+
140
+ Example: svcs diff --c1 1 --c2 3
141
+ """
142
+ vcs = SimpleVCS()
143
+ vcs.show_diff(c1, c2)
144
+
145
+ @main.command()
146
+ @click.option('--limit', type=int, help='Maximum number of commits to display')
147
+ def log(limit):
148
+ """Show commit history
149
+
150
+ Display a beautiful table of all commits with their messages, dates, and files.
151
+ Use --limit to show only recent commits.
152
+
153
+ Example: svcs log --limit 10
154
+ """
155
+ vcs = SimpleVCS()
156
+ vcs.show_log(limit)
157
+
158
+ @main.command()
159
+ def status():
160
+ """Show current repository status
161
+
162
+ Display information about the repository including current commit,
163
+ total commits, and staged files ready for commit.
164
+
165
+ Example: svcs status
166
+ """
167
+ vcs = SimpleVCS()
168
+ vcs.status()
169
+
170
+ @main.command()
171
+ @click.argument('commit_id', type=int)
172
+ def revert(commit_id):
173
+ """Revert to a specific commit
174
+
175
+ Quickly restore your repository to a previous commit state.
176
+ All files will be restored to their state at that commit.
177
+
178
+ Example: svcs revert 3
179
+ """
180
+ vcs = SimpleVCS()
181
+ vcs.quick_revert(commit_id)
182
+
183
+ @main.command()
184
+ @click.option('--name', help='Custom name for the snapshot (optional)')
185
+ def snapshot(name):
186
+ """Create a compressed snapshot
187
+
188
+ Creates a ZIP archive of your entire repository (excluding .svcs directory).
189
+ Perfect for backups or sharing your project.
190
+
191
+ Example: svcs snapshot --name my-backup
192
+ """
193
+ vcs = SimpleVCS()
194
+ vcs.create_snapshot(name)
195
+
196
+ @main.command()
197
+ @click.argument('snapshot_path', type=click.Path(exists=True))
198
+ def restore(snapshot_path):
199
+ """Restore from a snapshot
200
+
201
+ Restore your repository from a previously created snapshot ZIP file.
202
+ Current files will be replaced with snapshot contents.
203
+
204
+ Example: svcs restore snapshot_12345.zip
205
+ """
206
+ vcs = SimpleVCS()
207
+ vcs.restore_from_snapshot(snapshot_path)
208
+
209
+ @main.command()
210
+ def compress():
211
+ """Compress stored objects
212
+
213
+ Optimize repository storage by compressing object files.
214
+ Helps save disk space without losing any data.
215
+
216
+ Example: svcs compress
217
+ """
218
+ vcs = SimpleVCS()
219
+ vcs.compress_objects()
220
+
221
+ if __name__ == '__main__':
222
+ main()