PyCatFile 0.14.4__tar.gz → 0.14.6__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,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyCatFile
3
- Version: 0.14.4
3
+ Version: 0.14.6
4
4
  Summary: A tar like file format name catfile after unix cat command (concatenate files) .
5
5
  Home-page: https://github.com/GameMaker2k/PyCatFile
6
6
  Download-URL: https://github.com/GameMaker2k/PyCatFile/archive/master.tar.gz
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: PyCatFile
3
- Version: 0.14.4
3
+ Version: 0.14.6
4
4
  Summary: A tar like file format name catfile after unix cat command (concatenate files) .
5
5
  Home-page: https://github.com/GameMaker2k/PyCatFile
6
6
  Download-URL: https://github.com/GameMaker2k/PyCatFile/archive/master.tar.gz
@@ -14,7 +14,7 @@
14
14
  Copyright 2018-2024 Game Maker 2k - http://intdb.sourceforge.net/
15
15
  Copyright 2018-2024 Kazuki Przyborowski - https://github.com/KazukiPrzyborowski
16
16
 
17
- $FileInfo: pycatfile.py - Last Update: 11/17/2024 Ver. 0.14.4 RC 1 - Author: cooldude2k $
17
+ $FileInfo: pycatfile.py - Last Update: 11/17/2024 Ver. 0.14.6 RC 1 - Author: cooldude2k $
18
18
  '''
19
19
 
20
20
  from __future__ import absolute_import, division, print_function, unicode_literals, generators, with_statement, nested_scopes
@@ -29,6 +29,7 @@ import base64
29
29
  import shutil
30
30
  import socket
31
31
  import hashlib
32
+ import inspect
32
33
  import datetime
33
34
  import logging
34
35
  import binascii
@@ -207,10 +208,20 @@ except ImportError:
207
208
  from StringIO import StringIO
208
209
  from StringIO import StringIO as BytesIO
209
210
 
211
+ def get_importing_script_path():
212
+ # Inspect the stack and get the frame of the caller
213
+ stack = inspect.stack()
214
+ for frame_info in stack:
215
+ # In Python 2, frame_info is a tuple; in Python 3, it's a named tuple
216
+ filename = frame_info[1] if isinstance(frame_info, tuple) else frame_info.filename
217
+ if filename != __file__: # Ignore current module's file
218
+ return os.path.abspath(filename)
219
+ return None
220
+
210
221
  __use_pysftp__ = False
211
222
  __use_alt_format__ = False
212
223
  scriptconf = os.path.join(os.path.dirname(get_importing_script_path()), "catfile.ini")
213
- if os.path.exists(scriptconf)
224
+ if os.path.exists(scriptconf):
214
225
  __config_file__ = scriptconf
215
226
  else:
216
227
  __config_file__ = os.path.join(os.path.dirname(os.path.realpath(__file__)), "catfile.ini")
@@ -280,12 +291,12 @@ __file_format_dict__ = {'format_name': __file_format_name__, 'format_magic': __f
280
291
  'format_delimiter': __file_format_delimiter__, 'format_ver': __file_format_ver__, 'new_style': __use_new_style__, 'use_advanced_list': __use_advanced_list__, 'use_alt_inode': __use_alt_inode__}
281
292
  __project__ = __program_name__
282
293
  __project_url__ = "https://github.com/GameMaker2k/PyCatFile"
283
- __version_info__ = (0, 14, 4, "RC 1", 1)
294
+ __version_info__ = (0, 14, 6, "RC 1", 1)
284
295
  __version_date_info__ = (2024, 11, 17, "RC 1", 1)
285
296
  __version_date__ = str(__version_date_info__[0]) + "." + str(
286
297
  __version_date_info__[1]).zfill(2) + "." + str(__version_date_info__[2]).zfill(2)
287
298
  __revision__ = __version_info__[3]
288
- __revision_id__ = "$Id: a3b73d5aa307fac8e9dcb607ab975d4df22817d5 $"
299
+ __revision_id__ = "$Id: 14f7fa0575e0f4175f4395477a8edea992f704e2 $"
289
300
  if(__version_info__[4] is not None):
290
301
  __version_date_plusrc__ = __version_date__ + \
291
302
  "-" + str(__version_date_info__[4])
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes