myl 0.9.0__tar.gz → 0.9.1__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.
@@ -3,3 +3,4 @@
3
3
  *.egg-info
4
4
  build/
5
5
  dist/
6
+ result
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: myl
3
- Version: 0.9.0
3
+ Version: 0.9.1
4
4
  Summary: Dead simple IMAP CLI client
5
5
  Author-email: Philipp Schmitt <philipp@schmitt.co>
6
6
  License: GNU GENERAL PUBLIC LICENSE
@@ -721,15 +721,23 @@ straightforward way to interact with IMAP servers.
721
721
 
722
722
  To install myl, follow these steps:
723
723
 
724
- ```bash
724
+ ```shell
725
725
  pipx install myl
726
+ # or:
727
+ pip install --user myl
728
+ ```
729
+
730
+ on nix you can do this:
731
+
732
+ ```shell
733
+ nix run github.com:pschmitt/myl
726
734
  ```
727
735
 
728
736
  ## 🛠️ Usage
729
737
 
730
738
  Here's how you can use myl:
731
739
 
732
- ```bash
740
+ ```shell
733
741
  myl --help
734
742
  ```
735
743
 
@@ -737,7 +745,7 @@ This command will display the help information for the `myl` command.
737
745
 
738
746
  Here are some examples of using flags with the `myl` command:
739
747
 
740
- ```bash
748
+ ```shell
741
749
  # Connect to an IMAP server
742
750
  myl --server imap.example.com --port 143 --starttls --username "$username" --password "$password"
743
751
 
@@ -27,15 +27,23 @@ straightforward way to interact with IMAP servers.
27
27
 
28
28
  To install myl, follow these steps:
29
29
 
30
- ```bash
30
+ ```shell
31
31
  pipx install myl
32
+ # or:
33
+ pip install --user myl
34
+ ```
35
+
36
+ on nix you can do this:
37
+
38
+ ```shell
39
+ nix run github.com:pschmitt/myl
32
40
  ```
33
41
 
34
42
  ## 🛠️ Usage
35
43
 
36
44
  Here's how you can use myl:
37
45
 
38
- ```bash
46
+ ```shell
39
47
  myl --help
40
48
  ```
41
49
 
@@ -43,7 +51,7 @@ This command will display the help information for the `myl` command.
43
51
 
44
52
  Here are some examples of using flags with the `myl` command:
45
53
 
46
- ```bash
54
+ ```shell
47
55
  # Connect to an IMAP server
48
56
  myl --server imap.example.com --port 143 --starttls --username "$username" --password "$password"
49
57
 
myl-0.9.1/flake.lock ADDED
@@ -0,0 +1,27 @@
1
+ {
2
+ "nodes": {
3
+ "nixpkgs": {
4
+ "locked": {
5
+ "lastModified": 1730200266,
6
+ "narHash": "sha256-l253w0XMT8nWHGXuXqyiIC/bMvh1VRszGXgdpQlfhvU=",
7
+ "owner": "NixOS",
8
+ "repo": "nixpkgs",
9
+ "rev": "807e9154dcb16384b1b765ebe9cd2bba2ac287fd",
10
+ "type": "github"
11
+ },
12
+ "original": {
13
+ "owner": "NixOS",
14
+ "ref": "nixos-unstable",
15
+ "repo": "nixpkgs",
16
+ "type": "github"
17
+ }
18
+ },
19
+ "root": {
20
+ "inputs": {
21
+ "nixpkgs": "nixpkgs"
22
+ }
23
+ }
24
+ },
25
+ "root": "root",
26
+ "version": 7
27
+ }
myl-0.9.1/flake.nix ADDED
@@ -0,0 +1,81 @@
1
+ {
2
+ description = "flake for myl IMAP CLI client and myl-discovery";
3
+
4
+ inputs = {
5
+ nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
6
+ };
7
+
8
+ outputs =
9
+ { self, nixpkgs }:
10
+ let
11
+ pkgs = import nixpkgs {
12
+ system = "x86_64-linux";
13
+ };
14
+ in
15
+ {
16
+ packages.x86_64-linux.default = self.packages.x86_64-linux.myl;
17
+ packages.x86_64-linux.myl = pkgs.python3.pkgs.buildPythonApplication {
18
+ pname = "myl";
19
+ version = builtins.readFile ./version.txt;
20
+ pyproject = true;
21
+
22
+ src = ./.;
23
+
24
+ buildInputs = [
25
+ pkgs.python3.pkgs.setuptools
26
+ pkgs.python3.pkgs.setuptools-scm
27
+ ];
28
+
29
+ propagatedBuildInputs = with pkgs.python3.pkgs; [
30
+ html2text
31
+ imap-tools
32
+ self.packages.x86_64-linux.myl-discovery
33
+ rich
34
+ ];
35
+
36
+ meta = {
37
+ description = "Dead simple IMAP CLI client";
38
+ homepage = "https://pypi.org/project/myl/";
39
+ license = pkgs.lib.licenses.gpl3Only;
40
+ maintainers = with pkgs.lib.maintainers; [ pschmitt ];
41
+ mainProgram = "myl";
42
+ };
43
+ };
44
+
45
+ packages.x86_64-linux.myl-discovery = pkgs.python3.pkgs.buildPythonApplication rec {
46
+ pname = "myl-discovery";
47
+ version = "0.6.1";
48
+ pyproject = true;
49
+
50
+ src = pkgs.fetchPypi {
51
+ pname = "myl_discovery";
52
+ inherit version;
53
+ hash = "sha256-5ulMzqd9YovEYCKO/B2nLTEvJC+bW76pJtDu1cNXLII=";
54
+ };
55
+
56
+ buildInputs = [
57
+ pkgs.python3.pkgs.setuptools
58
+ pkgs.python3.pkgs.setuptools-scm
59
+ ];
60
+
61
+ propagatedBuildInputs = with pkgs.python3.pkgs; [
62
+ dnspython
63
+ exchangelib
64
+ requests
65
+ rich
66
+ xmltodict
67
+ ];
68
+
69
+ pythonImportsCheck = [ "myldiscovery" ];
70
+
71
+ meta = {
72
+ description = "Email autodiscovery";
73
+ homepage = "https://pypi.org/project/myl-discovery/";
74
+ license = pkgs.lib.licenses.gpl3Only;
75
+ maintainers = with pkgs.lib.maintainers; [ pschmitt ];
76
+ mainProgram = "myl-discovery";
77
+ };
78
+ };
79
+ };
80
+ }
81
+
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: myl
3
- Version: 0.9.0
3
+ Version: 0.9.1
4
4
  Summary: Dead simple IMAP CLI client
5
5
  Author-email: Philipp Schmitt <philipp@schmitt.co>
6
6
  License: GNU GENERAL PUBLIC LICENSE
@@ -721,15 +721,23 @@ straightforward way to interact with IMAP servers.
721
721
 
722
722
  To install myl, follow these steps:
723
723
 
724
- ```bash
724
+ ```shell
725
725
  pipx install myl
726
+ # or:
727
+ pip install --user myl
728
+ ```
729
+
730
+ on nix you can do this:
731
+
732
+ ```shell
733
+ nix run github.com:pschmitt/myl
726
734
  ```
727
735
 
728
736
  ## 🛠️ Usage
729
737
 
730
738
  Here's how you can use myl:
731
739
 
732
- ```bash
740
+ ```shell
733
741
  myl --help
734
742
  ```
735
743
 
@@ -737,7 +745,7 @@ This command will display the help information for the `myl` command.
737
745
 
738
746
  Here are some examples of using flags with the `myl` command:
739
747
 
740
- ```bash
748
+ ```shell
741
749
  # Connect to an IMAP server
742
750
  myl --server imap.example.com --port 143 --starttls --username "$username" --password "$password"
743
751
 
@@ -1,6 +1,8 @@
1
1
  .gitignore
2
2
  LICENSE
3
3
  README.md
4
+ flake.lock
5
+ flake.nix
4
6
  myl.py
5
7
  pyproject.toml
6
8
  .github/dependabot.yml
@@ -1,6 +1,7 @@
1
1
  #!/usr/bin/env python3
2
2
  # coding: utf-8
3
3
 
4
+ from importlib.metadata import version, PackageNotFoundError
4
5
  import argparse
5
6
  import logging
6
7
  import ssl
@@ -22,6 +23,11 @@ from rich.console import Console
22
23
  from rich.logging import RichHandler
23
24
  from rich.table import Table
24
25
 
26
+ try:
27
+ __version__ = version("myl")
28
+ except PackageNotFoundError:
29
+ pass
30
+
25
31
  LOGGER = logging.getLogger(__name__)
26
32
  IMAP_PORT = 993
27
33
  GMAIL_IMAP_SERVER = "imap.gmail.com"
@@ -70,6 +76,12 @@ def parse_args():
70
76
  subparsers = parser.add_subparsers(
71
77
  dest="command", help="Available commands"
72
78
  )
79
+ parser.add_argument(
80
+ "-V",
81
+ "--version",
82
+ action="version",
83
+ version=f"%(prog)s {__version__}",
84
+ )
73
85
 
74
86
  # Default command: list all emails
75
87
  subparsers.add_parser("list", help="List all emails")
@@ -21,7 +21,11 @@ dependencies = [
21
21
  "rich >= 13.0.0, <14.0.0",
22
22
  "html2text >= 2024.2.26"
23
23
  ]
24
- version = "0.9.0"
24
+ dynamic = ["version"]
25
+
26
+ [tool.setuptools_scm]
27
+ write_to = "version.txt"
28
+ version_file = "_version.py"
25
29
 
26
30
  [project.urls]
27
31
  homepage = "https://github.com/pschmitt/myl"
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes