airobo 0.1.7__py3-none-any.whl → 0.1.8__py3-none-any.whl

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.
airobo/api.py CHANGED
@@ -31,23 +31,34 @@ Get version from pyproject.toml
31
31
  """
32
32
  def version():
33
33
  try:
34
- # Get the directory where this file is located
34
+ # First try to get the directory where this file is located
35
35
  current_dir = os.path.dirname(os.path.abspath(__file__))
36
- # Go up one level to get to the project root
37
- project_root = os.path.dirname(current_dir)
38
- toml_path = os.path.join(project_root, 'pyproject.toml')
39
36
 
40
- if os.path.exists(toml_path):
41
- with open(toml_path, 'r') as f:
42
- content = f.read()
43
- # Extract version using regex
44
- version_match = re.search(r'version\s*=\s*"([^"]+)"', content)
45
- if version_match:
46
- print(version_match.group(1))
47
- return
37
+ # Try multiple possible locations for pyproject.toml
38
+ possible_paths = [
39
+ # In development: go up one level from airobo/ to project root
40
+ os.path.join(os.path.dirname(current_dir), 'pyproject.toml'),
41
+ # Alternative: same directory as this file
42
+ os.path.join(current_dir, 'pyproject.toml'),
43
+ # Alternative: current working directory
44
+ os.path.join(os.getcwd(), 'pyproject.toml')
45
+ ]
48
46
 
49
- # Fallback if file not found or version not found
50
- print("1337")
47
+ for toml_path in possible_paths:
48
+ if os.path.exists(toml_path):
49
+ with open(toml_path, 'r') as f:
50
+ content = f.read()
51
+ # Extract version using regex
52
+ version_match = re.search(r'version\s*=\s*["\']([^"\']+)["\']', content)
53
+ if version_match:
54
+ print(version_match.group(1))
55
+ return
56
+
57
+ # If no file found, fallback
58
+ print("0.1.7") # Use current known version as fallback
59
+ except Exception as e:
60
+ # Fallback on any error
61
+ print("0.1.7")
51
62
  except Exception:
52
63
  # Fallback on any error
53
64
  print("1337")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: airobo
3
- Version: 0.1.7
3
+ Version: 0.1.8
4
4
  Summary: A CLI tool for Airobo tasks
5
5
  Author-email: Joshua Morvant <joshua@aiarobo.com>
6
6
  Requires-Python: >=3.7
@@ -1,10 +1,10 @@
1
1
  airobo/__init__.py,sha256=wQC93xBJqTm_jHoO4hD_A9SP4vvVAMzOUM3vn_-bsB0,24
2
- airobo/api.py,sha256=dCFdAbxcKTgc6qw-Z0SqneGrD799L6AX8eU7MzcrjKA,1585
2
+ airobo/api.py,sha256=cCEozyDxs5sd-OLvMr2pTbmRQXXwVUVvSemZP2H8EbY,2102
3
3
  airobo/cli.py,sha256=81dIVLVrsVbJa_aZK7SNzT7dHc6aEB3jIaq4Fm5MBvo,991
4
4
  airobo/modules/publishAndroid.py,sha256=D1tmKAoYlIt85MhtOyAZXiVtscxiIgzFodqbVEbU_Ok,98
5
5
  airobo/modules/publishIOS.py,sha256=5HtnBejXtFNGJ719ydfKX0IO4hoJD5MlxKbmD-S7Dbg,90
6
- airobo-0.1.7.dist-info/METADATA,sha256=pa3PmkHDkiuVltnZc_gQKItozHwqISOdD_zeN-wICz0,207
7
- airobo-0.1.7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
- airobo-0.1.7.dist-info/entry_points.txt,sha256=tWld-TShvEFSonDWXCvsiBq-dNOY3Qo6FI48pd1S7eE,43
9
- airobo-0.1.7.dist-info/top_level.txt,sha256=3vchuQftD3xE45bZMuHJVTRVpiC8FKJyJwsrGAjfwKg,7
10
- airobo-0.1.7.dist-info/RECORD,,
6
+ airobo-0.1.8.dist-info/METADATA,sha256=ytIawaTNSoF8CVbsaXayxpSoBO1BICPDkMZ8bMomtQk,207
7
+ airobo-0.1.8.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
8
+ airobo-0.1.8.dist-info/entry_points.txt,sha256=tWld-TShvEFSonDWXCvsiBq-dNOY3Qo6FI48pd1S7eE,43
9
+ airobo-0.1.8.dist-info/top_level.txt,sha256=3vchuQftD3xE45bZMuHJVTRVpiC8FKJyJwsrGAjfwKg,7
10
+ airobo-0.1.8.dist-info/RECORD,,
File without changes