sharkit 0.2.0.dev2__py3-none-any.whl → 0.2.1.dev2__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.
sharkit/app.py CHANGED
@@ -20,7 +20,7 @@ NON_LINUX_MESSAGE = (
20
20
  "it was built for open water,\n"
21
21
  "where it can actually swim.\n"
22
22
  "\n"
23
- "windows/mac is more of a glass aquarium.\n"
23
+ "windows is more of a glass aquarium.\n"
24
24
  "tidy, bright, and a little too enclosed.\n"
25
25
  "\n"
26
26
  "the shark doesn't dislike the aquarium.\n"
@@ -37,7 +37,7 @@ def main() -> int:
37
37
  sys.stdout.flush()
38
38
  renderer = Renderer()
39
39
 
40
- if sys.platform != "linux":
40
+ if sys.platform == "win32":
41
41
  renderer.banner(tool_count=0, message=NON_LINUX_MESSAGE)
42
42
  return 1
43
43
 
@@ -382,7 +382,13 @@ class SetCommand(Command):
382
382
  tool_instance.set_option(key, value)
383
383
  renderer = context.session.get("renderer")
384
384
  if renderer is not None:
385
- renderer.log_line(f"set ({context.current_tool})", f"{key} = {value}")
385
+ tool_registry = context.session.get("tool_registry")
386
+ display = context.current_tool
387
+ if tool_registry is not None and context.current_tool is not None:
388
+ display = tool_registry.format_display(
389
+ tool_registry.get_tool_path(context.current_tool),
390
+ )
391
+ renderer.log_line(f"set {display}", f"{key} = {value}")
386
392
  return None
387
393
  return f"Set {key} = {value}"
388
394
  except Exception as e:
sharkit/tools/manager.py CHANGED
@@ -96,4 +96,7 @@ class ToolManager:
96
96
  return False, f'Failed to uninstall "{name}": {e}'
97
97
 
98
98
  def _run(self, cmd: list[str]) -> None:
99
- subprocess.run(cmd, check=True, capture_output=True)
99
+ result = subprocess.run(cmd, capture_output=True, text=True)
100
+ if result.returncode != 0:
101
+ detail = result.stderr.strip() or result.stdout.strip() or "No output"
102
+ raise RuntimeError(detail)
@@ -191,6 +191,8 @@ class BlackbirdTool(Tool):
191
191
  proc.kill()
192
192
  current = ""
193
193
  if renderer is not None:
194
+ # \r\033[K clears the ^C echo from the terminal before printing.
195
+ print("\r\033[K", end="")
194
196
  renderer.gutter(name, "Run aborted (Ctrl+C).", tool_color, first)
195
197
  else:
196
198
  print("Run aborted (Ctrl+C).")
@@ -233,6 +233,7 @@ class MaigretTool(Tool):
233
233
  proc.kill()
234
234
  current = ""
235
235
  if renderer is not None:
236
+ print("\r\033[K", end="")
236
237
  renderer.gutter(name, "Run aborted (Ctrl+C).", tool_color, first)
237
238
  else:
238
239
  print("Run aborted (Ctrl+C).")
@@ -233,6 +233,7 @@ class SherlockTool(Tool):
233
233
  proc.kill()
234
234
  current = ""
235
235
  if renderer is not None:
236
+ print("\r\033[K", end="")
236
237
  renderer.gutter(name, "Run aborted (Ctrl+C).", tool_color, first)
237
238
  else:
238
239
  print("Run aborted (Ctrl+C).")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.5
2
2
  Name: sharkit
3
- Version: 0.2.0.dev2
3
+ Version: 0.2.1.dev2
4
4
  Summary: OSINT / HUMINT / GEOINT research framework
5
5
  Project-URL: Homepage, https://github.com/sshsrv/sharkit
6
6
  Project-URL: Repository, https://github.com/sshsrv/sharkit
@@ -1,10 +1,10 @@
1
1
  sharkit/__init__.py,sha256=OGzj-VcV47eHlCtE4iYrCpqTRaz__KMtAZsSih9qTlo,182
2
2
  sharkit/__main__.py,sha256=WhOrG3AfMu5ofmKLwPVkUkGWmR5Caeauvy1PF_E1aeE,59
3
- sharkit/app.py,sha256=Tyb2hAJBEwBtIolXAyPRTqPBkrY3xGEjI2J6iEhSVF0,2273
3
+ sharkit/app.py,sha256=POa4kRLzIfmUYn1gjAVeNZQdV71SUABofwPtICDQ9Fc,2269
4
4
  sharkit/exceptions.py,sha256=ZQ81jUf746YL4nwHNPZOf28wAL9GbJ9NAYKgSMeCuL8,1243
5
5
  sharkit/commands/__init__.py,sha256=Bw1EHcggzxP5qSbXzjOw-YipXvfPRQF-j4SGCdPreLA,266
6
6
  sharkit/commands/base.py,sha256=5wYCKN4dgHZpYPGRSFW8CSDzU_mqZf8MA7hGkokvMPg,1268
7
- sharkit/commands/builtins.py,sha256=T4p4UEx7IaEP8oxjbePE-tropY9bwnHfDBKwtphqTCA,30284
7
+ sharkit/commands/builtins.py,sha256=278bOXgB5qGY30u45ZptTLgehPvL5RFmAk2bH9SND7s,30625
8
8
  sharkit/commands/registry.py,sha256=Q-OLT-IAaBMmLLUbXqhinV5bT7NYbOFUyuISEmSSstQ,1157
9
9
  sharkit/config/__init__.py,sha256=4JHarTFGaZ4ITZQiQvZvs95tie3SPM1uox0lxKHQkFc,332
10
10
  sharkit/config/manager.py,sha256=WwF3fwBIsj0YinIcv9g2OemHBc32ITWZlzJJFNz46aw,2434
@@ -23,13 +23,13 @@ sharkit/output/theme.py,sha256=MQQSnAVhIYa7sVL7G2h_-dL507GM9YudPFKG2Ru11VQ,484
23
23
  sharkit/tools/__init__.py,sha256=W5l92WiuEVRJgA-jPk8kQiZpftczYYIWkcEcf0iMZ0g,475
24
24
  sharkit/tools/base.py,sha256=R0f3ZAo6sJWy9oaXPzM89AiUzvcXJfECTB-16LN0ZzY,1935
25
25
  sharkit/tools/loader.py,sha256=nBFl9u-CFt2-Ubtaf5sX1jisuCiK5fC5M2uBQtnq_Ak,1639
26
- sharkit/tools/manager.py,sha256=8QS3UAQMvTHgifDyJmVqH675b9WjQI63N5yeqS1ZX3g,3906
26
+ sharkit/tools/manager.py,sha256=oEMeuU19sUBmUii9askJiyZDYLmUzBbckBZMiJiNQwo,4071
27
27
  sharkit/tools/registry.py,sha256=7pnQXDNM5UfOSQs1P7s_DrJ3B7oulydBGT-fj82v09k,3041
28
- sharkit/tools/osint/recon/hybrid/blackbird.py,sha256=BU5TGPgbaEfDAsnSPiyjs7uZyc7NZCbV1TgdNWfpLks,7314
29
- sharkit/tools/osint/recon/username/maigret.py,sha256=fnsjW659HZ1TJrdJUJi5FR1_fGA-f9TxmeH6LvjrGeQ,8484
30
- sharkit/tools/osint/recon/username/sherlock.py,sha256=nD775uCQtUPf2p5_WlasPKOf4YR3HWI6DppZkFz8_K8,8503
31
- sharkit-0.2.0.dev2.dist-info/METADATA,sha256=CW-jccLkb-ZWPyxPXQHndT_MushDkpGplSyUdQNpgNw,3129
32
- sharkit-0.2.0.dev2.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
33
- sharkit-0.2.0.dev2.dist-info/entry_points.txt,sha256=yc51tEJlCyl1fXO9RugLwzMXp4OB7IHr50whA26ABnQ,45
34
- sharkit-0.2.0.dev2.dist-info/licenses/LICENSE,sha256=QQl3gG-R24BhFoL6uwKx1CiQqokgqQrIG5hPRiIA25s,1077
35
- sharkit-0.2.0.dev2.dist-info/RECORD,,
28
+ sharkit/tools/osint/recon/hybrid/blackbird.py,sha256=MMem_wYylWekblhG-mMELUM2xj_J6fn69Kqq8q4MSo8,7437
29
+ sharkit/tools/osint/recon/username/maigret.py,sha256=-H1d0Gwj8BZ5CSpgWvFdhLrL4pdSwd45FY78CY-q8Cc,8526
30
+ sharkit/tools/osint/recon/username/sherlock.py,sha256=4IbVCCLLa7rGW92GXxFiiUftRXGbpW9MsuFPUhOH1Zk,8545
31
+ sharkit-0.2.1.dev2.dist-info/METADATA,sha256=hrrLZvjtvx4JcdGV6hTuh0aL0sHDxHt641aee4YzZDs,3129
32
+ sharkit-0.2.1.dev2.dist-info/WHEEL,sha256=zOwg4jB6zX2kU910N-cMawjivD6tO8NEWvE12je1bVk,87
33
+ sharkit-0.2.1.dev2.dist-info/entry_points.txt,sha256=yc51tEJlCyl1fXO9RugLwzMXp4OB7IHr50whA26ABnQ,45
34
+ sharkit-0.2.1.dev2.dist-info/licenses/LICENSE,sha256=QQl3gG-R24BhFoL6uwKx1CiQqokgqQrIG5hPRiIA25s,1077
35
+ sharkit-0.2.1.dev2.dist-info/RECORD,,