Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(deno): support for custom deny permissions #286

Merged
merged 1 commit into from
May 23, 2024
Merged

Conversation

wellwelwel
Copy link
Owner

@wellwelwel wellwelwel commented May 23, 2024

deny

deny: string[]

Change permissions for Deno.

API (in-code)

poku(['...'], {
  deno: {
    deny: ['write', 'sys' /* ... */],
  },
});
poku(['...'], {
  deno: {
    deny: ['env=HOME', 'write' /* ... */],
  },
});

CLI

npx poku --deno-deny='write, sys' ./test
npx poku --deno-deny='env=HOME, write' ./test

@wellwelwel wellwelwel marked this pull request as ready for review May 23, 2024 05:25
Copy link

codecov bot commented May 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.02%. Comparing base (4e551f6) to head (83ad1c8).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #286      +/-   ##
==========================================
+ Coverage   94.00%   94.02%   +0.01%     
==========================================
  Files          31       31              
  Lines        2468     2476       +8     
  Branches      386      363      -23     
==========================================
+ Hits         2320     2328       +8     
  Misses        146      146              
  Partials        2        2              
Flag Coverage Δ
linux-parallel 93.73% <100.00%> (+0.02%) ⬆️
linux-parallel-options 93.94% <100.00%> (+0.01%) ⬆️
linux-sequential 92.32% <100.00%> (+0.02%) ⬆️
linux-sequential-options 92.48% <100.00%> (+0.02%) ⬆️
osx-parallel 93.73% <100.00%> (+0.02%) ⬆️
osx-parallel-options 93.94% <100.00%> (+0.01%) ⬆️
osx-sequential 92.32% <100.00%> (+0.02%) ⬆️
osx-sequential-options 92.48% <100.00%> (+0.02%) ⬆️
windows-parallel 93.21% <100.00%> (+0.02%) ⬆️
windows-parallel-options 93.41% <100.00%> (+0.02%) ⬆️
windows-sequential 91.80% <100.00%> (+0.02%) ⬆️
windows-sequential-options 91.96% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@wellwelwel wellwelwel merged commit 3172c4b into main May 23, 2024
38 checks passed
@wellwelwel wellwelwel deleted the deno-deny branch May 23, 2024 05:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant