Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
93 commits
Select commit Hold shift + click to select a range
42e9219
introduce GitHub Actions
shogo82148 Jul 31, 2021
ed6d2f5
Add lint+vet+old versions to GitHub Action
Code0x58 Aug 1, 2021
5ce1ba4
Remove Travis CI and references
Code0x58 Aug 1, 2021
2fb15b1
Drop support/testing for Go 1.11 and earlier (#381)
nshalman Aug 4, 2021
cc8365b
Update x/sys to latest (#379)
nshalman Aug 4, 2021
16f0d42
add //go:build lines + add 1.17.0-rc2 to test matrix (#377)
shogo82148 Aug 4, 2021
82ee6f3
Update test matrix for go 1.17 stable release (#385)
nshalman Aug 17, 2021
e2e9517
Add AddRaw to not follow symlinks + Fix link folloing on Windows (#289)
Code0x58 Aug 18, 2021
08848a0
v1.5.0 preparation (#380)
Code0x58 Aug 18, 2021
dfdb645
revise pull request template
nathany Aug 24, 2021
b98ede5
Revert "Add AddRaw to not follow symlinks + Fix link folloing on Wind…
nathany Aug 24, 2021
466b39d
prepare 1.5.1, retract 1.5.0
nathany Aug 24, 2021
3eb7fa4
Removed dead link
COil May 7, 2020
0aba082
Update issue templates (#410)
nathany Jan 14, 2022
83f9fe6
Test on Go 1.18 and two most recent versions (#411)
nathany Jan 14, 2022
6e1d4e4
update readme
nathany Jan 14, 2022
d696f5c
revise contributing
nathany Jan 14, 2022
62a598a
maintainers wanted
nathany Jan 14, 2022
af855d7
Final Notice: Maintainers Wanted
nathany Jan 14, 2022
73c3b57
fix go vet warnings: call to (*T).Fatalf from a non-test goroutine (#…
shogo82148 Jan 17, 2022
c11d74b
Run cross-compilation builds on every push (#420)
nshalman Jan 19, 2022
508ee5e
Don't set poller.fd twice in newFdPoller (#406)
tklauser Jan 19, 2022
ebaf806
Re-enable tests for PRs (#415)
nshalman Jan 20, 2022
f10a232
Enable cross-compilation builds on PRs (#423)
nshalman Jan 20, 2022
f482481
Integration Tests: consistent sleeps with informative names (#422)
nshalman Jan 20, 2022
c4cd7f3
Add FreeBSD testing in Github Actions (#419)
r-darwish Jan 24, 2022
bfa0135
Allow build on unsupported GOOS (#424)
tklauser Jan 25, 2022
712fe1d
Fix potential crash on windows if raw.FileNameLength exceeds syscall.…
hu13 Jan 26, 2022
ceba4ef
Add a feature to return the directories and files that are being moni…
NitroCao Apr 21, 2022
8fa037f
Fix compilation for OpenBSD (#443)
mattn Apr 21, 2022
243d395
go.mod: use latest x/sys (#444)
kevinburkesegment Apr 24, 2022
b52bbe8
README.md: link to pkg.go.dev for golang.org/x/sys package (#441)
tklauser Apr 24, 2022
97640bb
Windows: add missing defer to Watcher.WatchList (#447)
Sojamann Apr 24, 2022
0f4b979
Prepare for v1.5.4 (#448)
shogo82148 Apr 27, 2022
37badf6
This project is archived (#459)
nathany Jul 8, 2022
c56cafd
Test Go 1.18
arp242 Jul 21, 2022
5acfdc1
windows: protect access to isClosed with mutex (#454)
rfratto Jul 21, 2022
1a4f949
Use common error when removing an unwatched file (#460)
arp242 Jul 21, 2022
217e78e
Explicit mutext (un)locking (#462)
Jul 21, 2022
adf5320
strings.Builder instead of bytes.Buffer (#285)
ilanpillemer Jul 21, 2022
6ae56b7
kqueue: Make watcher.Close() O(n) instead of O(n^2) (#233)
nicks Jul 21, 2022
4193dfd
Do not suppress Chmod on non-existent file (#260)
kolyshkin Jul 21, 2022
808f582
bump up GitHub Actions (#461)
shogo82148 Jul 21, 2022
4678dfd
Update documentation for linux systems (max_user_watches) (#287)
saschagrunert Jul 21, 2022
e56409e
Update link to CONTRIBUTING in the README (#464)
jolheiser Jul 22, 2022
35b6378
Clarify README on network drives (#467)
arp242 Jul 22, 2022
7fe2936
inotify: fix race in Close() (#465)
arp242 Jul 22, 2022
548b8fb
Add missing changelog for 1.4.{8,9} (#468)
arp242 Jul 24, 2022
4b8b298
Test some more things in CI (#469)
arp242 Jul 24, 2022
c4e64e4
Replace Use of Kthread-blocking Epoll with Poller Read, Remove Per-Ev…
horahoradev Jul 24, 2022
cc15908
kqueue: better error if watching a file fails (#471)
arp242 Jul 29, 2022
d9c9fa5
Add cmd/fsnotify (#463)
arp242 Jul 29, 2022
f0aceb2
Tweak comment regarding relative paths (#466)
arp242 Jul 29, 2022
1a7b6ef
inotify: don't ignore events for files that don't exist (#470)
arp242 Jul 29, 2022
0e78fa6
Update README: split out FAQ to "Platform-specific notes"
arp242 Jul 29, 2022
a3256ef
Remove AUTHORS file
arp242 Jul 29, 2022
421f529
debian 6 test: deal with multiple packages (#474)
arp242 Jul 29, 2022
ff39bb4
Fix lint (#476)
arp242 Jul 30, 2022
ca0e2f4
macos: retry if open() returns EINTR (#475)
arp242 Jul 30, 2022
60fbf57
Clarify FAQ on goroutines
arp242 Jul 30, 2022
39823aa
Document that /proc and /sys won't work
arp242 Jul 30, 2022
57e6a49
Add {Event,Op}.Has() (#477)
arp242 Jul 30, 2022
87dc1fa
Rewrite tests (#478)
arp242 Jul 31, 2022
f174f95
windows: update watch paths when renaming directories with sub-watche…
arnegroskurth Jul 31, 2022
928895c
[bugfix] close handle when remWatch open in getIno (#288)
brokenjacky Jul 31, 2022
666c6a0
Update ChangeLog
arp242 Jul 31, 2022
a58e868
Run tests in illumos (#481)
arp242 Aug 1, 2022
01dfc6f
Remove PULL_REQUEST_TEMPLATE
arp242 Aug 2, 2022
a566bb1
Update CONTRIBUTING.md
arp242 Aug 2, 2022
4604469
Need Linux 5.9 for a useful fanotify we can use
arp242 Aug 3, 2022
f2d35c3
Remove CLA section in contributing
arp242 Aug 3, 2022
a5c5815
ci: update to use Go 1.19, kick off fewer builds, update x/sys (#484)
arp242 Aug 3, 2022
99715ba
windows: increase buffer size from 4K to 64K (#485)
arp242 Aug 4, 2022
1f8edaf
windows: replace "e" with "err" for error variables
arp242 Aug 4, 2022
5dcbfba
windows: replace syscall with golang.org/x/sys/windows
arp242 Aug 4, 2022
9dd0568
cmd/fsnotify: fix time.Format() string
arp242 Aug 4, 2022
ee33a65
Use "os.Rename()" in tests instead of "mv"
arp242 Aug 5, 2022
f45391f
windows: run TestWatchRename/rename_overwriting_existing_file (#490)
arp242 Aug 5, 2022
a24f78c
windows: test symlinks (#491)
arp242 Aug 5, 2022
4b43fad
kqueue: remove timeout from unix.Kevent() (#480)
arp242 Aug 6, 2022
a4bcdf8
Update changelog
arp242 Aug 6, 2022
8ab3b84
kqueue: don't set up watchers on unreadable files (#479)
arp242 Aug 6, 2022
2bfaa00
all: add Watcher.{sendEvent,sendError} (#492)
arp242 Aug 6, 2022
5b87f50
windows: simplify a bit (#493)
arp242 Aug 6, 2022
844d71f
Port minor test changes from fen-v2 branch; make LICENSE text not ugly
arp242 Aug 6, 2022
fdf41a3
Move some files around
arp242 Aug 6, 2022
e180a87
Move some inotify-tests to run on all backends; test that state is cl…
arp242 Aug 8, 2022
61a05ce
Update documentation and examples (#496)
arp242 Aug 10, 2022
123e4e3
Add note about README version
arp242 Aug 10, 2022
666da9c
Clarify doc comment on WatchList() (#499)
arp242 Aug 10, 2022
fb07f82
Add test to see what happens if you watch a symlink (#498)
arp242 Aug 10, 2022
69c24b0
Update x/sys
arp242 Aug 26, 2022
588ded0
Merge branch 'main' into preveil
hu13 Aug 29, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions .github/PULL_REQUEST_TEMPLATE.md

This file was deleted.

6 changes: 6 additions & 0 deletions .github/workflows/Vagrantfile.debian6
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Vagrant.configure("2") do |config|
config.vm.box = "threatstack/debian6"
config.vm.box_version = "1.0.0"

config.vm.define 'debian6'
end
27 changes: 27 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: 'build'
on:
push:
paths: ['**.go', 'go.mod', '.github/workflows/*']

jobs:
cross-compile:
strategy:
fail-fast: false
matrix:
go: ['1.16', '1.19']
runs-on: ubuntu-latest
steps:
- name: setup Go
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go }}

- name: checkout
uses: actions/checkout@v3

- name: build
run: |
set -x
for a in $(go tool dist list); do
GOOS=${a%%/*} GOARCH=${a#*/} go build
done
16 changes: 16 additions & 0 deletions .github/workflows/staticcheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: 'staticcheck'
on:
push:
paths: ['**.go', 'go.mod', '.github/workflows/*']

jobs:
staticcheck:
name: 'staticcheck'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
- uses: dominikh/staticcheck-action@v1.2.0
with:
version: '2022.1'
155 changes: 130 additions & 25 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,57 +1,162 @@
name: test
on: [push]
name: 'test'
on:
push:
paths: ['**.go', 'go.mod', '.github/workflows/*']

jobs:
# Test Windows and Linux with the latest Go version and the oldest we support.
test:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
go:
- '1.18.0-beta1'
- '1.17'
- '1.16'
- '1.19'
runs-on: ${{ matrix.os }}
steps:
- name: setup Go
uses: actions/setup-go@v2
uses: actions/setup-go@v3
with:
stable: 'false'
go-version: ${{ matrix.go }}

- name: checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: test
run: |
go test --race ./...
go test -race ./...

lint:
runs-on: ubuntu-latest
# Test only the latest Go version on macOS; we use the macOS builders for BSD
# and illumos, and GitHub doesn't allow many of them to run concurrently. If
# it works on Windows and Linux with Go 1.16, then it probably does on macOS
# too.
testMacOS:
name: test
strategy:
fail-fast: false
matrix:
os:
- macos-11
- macos-12
go:
- '1.19'
runs-on: ${{ matrix.os }}
steps:
- name: setup Go
uses: actions/setup-go@v2
with:
go-version: '1.17'
uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go }}

- name: checkout
uses: actions/checkout@v2
uses: actions/checkout@v3

- name: gofmt
- name: test
run: |
test -z "$(gofmt -s -d . | tee /dev/stderr)"
go test -race ./...

# FreeBSD
testFreeBSD:
runs-on: macos-12
name: test (freebsd, 1.18)
steps:
- uses: actions/checkout@v3
- name: test (freebsd, 1.18)
id: test
uses: vmactions/freebsd-vm@v0.2.0
with:
usesh: true
prepare: pkg install -y go
run: |
pw user add -n action -m
su action -c 'go test -race ./...'

# OpenBSD; no -race as the VM doesn't include the comp set.
#
# TODO: should probably add this, but on my local machine the tests time out
# with -race as the waits aren't long enough (OpenBSD is kind of slow),
# so should probably look into that first. Go 1.19 is supposed to have a
# much faster race detector, so maybe waiting until we have that is
# enough.
testOpenBSD:
runs-on: macos-12
name: test (openbsd, 1.17)
steps:
- uses: actions/checkout@v3
- name: test (openbsd, 1.17)
id: test
uses: vmactions/openbsd-vm@v0.0.6
with:
prepare: pkg_add go
run: |
useradd -mG wheel action
su action -c 'go test ./...'

- name: vet
# NetBSD
testNetBSD:
runs-on: macos-12
name: test (netbsd, 1.18)
steps:
- uses: actions/checkout@v3
- name: test (netbsd, 1.18)
id: test
uses: vmactions/netbsd-vm@v0.0.4
with:
prepare: pkg_add go
# TODO: no -race for the same reason as OpenBSD (the timing; it does run).
run: |
useradd -mG wheel action
su action -c 'go118 test ./...'

# illumos
testillumos:
runs-on: macos-12
name: test (illumos, 1.17)
steps:
- uses: actions/checkout@v2
- name: test (illumos, 1.17)
id: test
uses: papertigers/illumos-vm@r38
with:
prepare: |
pkg install go-117
run: |
go vet ./...
/opt/ooce/go-1.17/bin/go test ./...

# Older Debian 6, for old Linux kernels.
testDebian6:
runs-on: macos-12
name: test (debian6, 1.19)
strategy:
fail-fast: false
steps:
- uses: actions/checkout@v3

- name: golangci-lint
uses: golangci/golangci-lint-action@v2
continue-on-error: true
- name: Cache Vagrant boxes
uses: actions/cache@v3
with:
version: latest
skip-go-installation: true

path: ~/.vagrant.d/boxes
key: ${{ runner.os }}-vagrant-${{ hashFiles('Vagrantfile') }}
restore-keys: |
${{ runner.os }}-vagrant-

- name: setup Go
uses: actions/setup-go@v3
with:
go-version: '1.19'

- name: test (debian6, 1.19)
id: test
run: |
cp -f .github/workflows/Vagrantfile.debian6 Vagrantfile
export GOOS=linux
export GOARCH=amd64
for p in $(go list ./...); do
go test -c -o ${p//\//-}.test $p
done
vagrant up
for t in *.test; do
vagrant ssh -c "/vagrant/$t"
done
8 changes: 5 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# Setup a Global .gitignore for OS and editor generated files:
# https://help.github.com/articles/ignoring-files
# git config --global core.excludesfile ~/.gitignore_global
# go test -c output
*.test
*.test.exe

.vagrant
*.sublime-project
bin/**
# Output of go build ./cmd/fsnotify
/fsnotify
62 changes: 0 additions & 62 deletions AUTHORS

This file was deleted.

Loading