-
Notifications
You must be signed in to change notification settings - Fork 11
Idea: osquery integration with xonsh shell #53
Copy link
Copy link
Open
Labels
Description
The initial idea in #52. The same could be for https://osquery.io/
def osq(query):
json_data = $(osqueryi --json @(query))
df = @.imp.pandas.DataFrame(@.imp.json.loads(json_data))
return df
files_df = osq('select pid, name from processes')
files_df
# DataFrameor with macro
def osq(*a, **kw):
json_data = $(osqueryi --json @(', '.join(a)))
df = @.imp.pandas.DataFrame(@.imp.json.loads(json_data))
return df
files_df = osq!(select pid, name from processes)
files_df
# DataFrameFor community
⬇️ Please click the 👍 reaction instead of leaving a +1 or 👍 comment
Reactions are currently unavailable