Skip to content

Commit 5fd216b

Browse files
committed
docs: add security check to key features
1 parent 7c0bfa5 commit 5fd216b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+852
-250
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,4 @@ homebrew-tap/
3333
dist/
3434
.agent/
3535
.ask/
36+
ask.lock

.golangci.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
version: 2
2+
3+
run:
4+
timeout: 5m
5+
tests: true
6+
7+
linters-settings:
8+
govet:
9+
enable-all: true
10+
disable:
11+
- fieldalignment
12+
misspell:
13+
locale: US
14+
revive:
15+
rules:
16+
- name: exported
17+
severity: warning
18+
- name: package-comments
19+
severity: warning
20+
- name: error-naming
21+
severity: warning
22+
- name: error-strings
23+
severity: warning
24+
- name: error-return
25+
severity: warning
26+
- name: var-naming
27+
severity: warning
28+
- name: context-keys-type
29+
severity: warning
30+
- name: time-naming
31+
severity: warning
32+
- name: unexported-return
33+
severity: warning
34+
- name: indent-error-flow
35+
severity: warning
36+
- name: blank-imports
37+
severity: warning
38+
- name: context-as-argument
39+
severity: warning
40+
- name: unused-parameter
41+
severity: warning
42+
- name: unreachable-code
43+
severity: warning
44+
- name: redefines-builtin-id
45+
severity: warning
46+
47+
linters:
48+
disable-all: true
49+
enable:
50+
- govet
51+
- staticcheck
52+
- misspell
53+
- revive
54+
- ineffassign
55+
- errcheck
56+
57+
issues:
58+
exclude-use-default: false
59+
max-issues-per-linter: 0
60+
max-same-issues: 0

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
### Added
1111
- **Security Checks**: New `ask check` command to scan skills for secrets, dangerous commands, and suspicious files.
12-
- **Security Reports**: Generate detailed security reports in Markdown or HTML with `ask check --report <file>`.
12+
- **Values Reports**: Generate detailed security reports in Markdown, HTML, or JSON with `ask check -o <file>`.
1313
- **Entropy Analysis**: Smart secret detection using Shannon entropy to reduce false positives.
1414

1515
## [1.0.0-rc2] - 2026-01-24

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ By participating in this project, you agree to maintain a respectful and inclusi
2020

2121
### Prerequisites
2222

23-
- Go 1.21 or higher
23+
- Go 1.24 or higher
2424
- Git
2525
- A GitHub account
2626

@@ -195,7 +195,7 @@ Before submitting, ensure:
195195
- [ ] Code builds successfully (`make build`)
196196
- [ ] All tests pass (`make test`)
197197
- [ ] Code is formatted (`make fmt`)
198-
- [ ] No linter warnings (`make vet`)
198+
- [ ] No linter warnings (`make lint`)
199199
- [ ] Documentation is updated (if needed)
200200
- [ ] CHANGELOG.md is updated (if applicable)
201201
- [ ] Commit messages follow convention

README.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
<a href="https://github.com/yeasy/ask/blob/main/LICENSE"><img src="https://img.shields.io/github/license/yeasy/ask?style=flat-square" alt="License"></a>
1818
<a href="https://github.com/yeasy/ask/stargazers"><img src="https://img.shields.io/github/stars/yeasy/ask?style=flat-square" alt="Stars"></a>
1919
<a href="https://goreportcard.com/report/github.com/yeasy/ask"><img src="https://goreportcard.com/badge/github.com/yeasy/ask?style=flat-square" alt="Go Report Card"></a>
20-
<img src="https://img.shields.io/badge/Go-1.21+-00ADD8?style=flat-square&logo=go" alt="Go Version">
20+
<img src="https://img.shields.io/badge/Go-1.24+-00ADD8?style=flat-square&logo=go" alt="Go Version">
2121
</p>
2222

2323
<p align="center">
@@ -60,7 +60,8 @@ graph LR
6060
| **🤖 Multi-Agent** | Auto-detects and installs for **Claude** (`.claude/`), **Cursor** (`.cursor/`), **Codex** (`.codex/`), and more. |
6161
| **⚡ Blazing Fast** | Written in Go. Parallel downloads, sparse checkouts, and zero runtime dependencies. |
6262
| **🔌 Offline Mode** | Full offline support with `--offline`. Perfect for air-gapped or secure environments. |
63-
| **🌍 Global & Local** | Manage project-specific skills (`.agent/skills`) or user-wide tools (`~/.ask/skills`). |
63+
| **🌎 Global & Local** | Manage project-specific skills (`.agent/skills`) or user-wide tools (`~/.ask/skills`). |
64+
| **🛡️ Security Guard** | Built-in security scanner checks skills for secrets, dangerous commands, and malware using entropy analysis. |
6465

6566
## 🚀 Quick Start
6667

@@ -99,10 +100,11 @@ ask install mcp-builder@v1.0.0
99100

100101
# Install for specific agent
101102
ask install mcp-builder --agent claude
103+
ask install mcp-builder --agent claude cursor
102104

103105
# Security Check
104106
ask check .
105-
ask check anthropics/mcp-builder --report report.html
107+
ask check anthropics/mcp-builder -o report.html
106108
```
107109

108110
## 📋 Commands
@@ -170,6 +172,15 @@ my-project/
170172
- **Cursor**: `.cursor/skills/`
171173
- **Codex**: `.codex/skills/`
172174

175+
## 🐞 Debugging
176+
177+
To see detailed operational logs (scanning, updating, searching), set `ASK_LOG=debug`:
178+
179+
```bash
180+
export ASK_LOG=debug
181+
ask skill install browser-use
182+
```
183+
173184
## 🤝 Contributing
174185
Contributions are welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for details.
175186

README_zh.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@ graph LR
5959
| **🤖 多 Agent 支持** | 自动检测并适配 **Claude** (`.claude/`)、**Cursor** (`.cursor/`)、**Codex** (`.codex/`) 等环境。 |
6060
| **⚡ 极速体验** | 纯 Go 语言编写。支持并发下载、稀疏检出 (Sparse Checkout),无运行时依赖,毫秒级响应。 |
6161
| **🔌 离线模式** | 支持 `--offline` 离线模式,优先使用本地缓存,完美适配内网或安全受限环境。 |
62-
| **🌍 全局与本地** | 灵活支持项目级 (`.agent/skills`) 和用户级 (`~/.ask/skills`) 隔离管理。 |
62+
| **🌎 全局与本地** | 灵活支持项目级 (`.agent/skills`) 和用户级 (`~/.ask/skills`) 隔离管理。 |
63+
| **🛡️ 安全守卫** | 内置安全扫描引擎,通过熵值分析检测敏感信息泄漏、危险命令及恶意代码,为智能体保驾护航。 |
6364

6465
## 🚀 快速开始
6566

@@ -102,7 +103,7 @@ ask install mcp-builder --agent claude
102103

103104
# 安全检查
104105
ask check .
105-
ask check anthropics/mcp-builder --report report.html
106+
ask check anthropics/mcp-builder -o report.html
106107
```
107108

108109
## 📋 命令参考

ask.lock

Lines changed: 0 additions & 44 deletions
This file was deleted.

cmd/benchmark.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// Package cmd provides the command line interface logic for ask.
12
package cmd
23

34
import (
@@ -17,7 +18,7 @@ var benchmarkCmd = &cobra.Command{
1718
Use: "benchmark",
1819
Short: "Run performance benchmarks",
1920
Long: `Measure the performance of key CLI operations like search, list, and info.`,
20-
Run: func(cmd *cobra.Command, args []string) {
21+
Run: func(_ *cobra.Command, _ []string) {
2122
fmt.Println("Running benchmarks...")
2223
fmt.Println()
2324

0 commit comments

Comments
 (0)