Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
28 changes: 28 additions & 0 deletions .github/workflows/license.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: License

on:
push:
branches:
- master
pull_request:
types:
- opened
- reopened
- synchronize

jobs:
license:
name: License
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- name: Check out
uses: actions/checkout@v6

- name: Check License Header
uses: apache/skywalking-eyes/header@main

- name: Check Dependencies' License
uses: apache/skywalking-eyes/dependency@main
37 changes: 37 additions & 0 deletions .licenserc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
header:
license:
spdx-id: Apache-2.0
copyright-owner: Basil Crow
pattern: |
Copyright \d{4}(, \d{4})* (Basil Crow|Delphix)

Licensed under the Apache License, Version 2.0 \(the "License"\);
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

paths-ignore:
- '**/*.md'
- '.git-blame-ignore-revs'
- '.gitattributes'
- '.github/**'
- '.gitignore'
- '.licenserc.yaml'
- '.markdownlint.json'
- 'Cargo.lock'
- 'Cargo.toml'
- 'LICENSE'

comment: on-failure

dependency:
files:
- Cargo.toml
16 changes: 16 additions & 0 deletions build.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use roff::{bold, roman, Roff};
use std::fs;
use std::path::Path;
Expand Down
16 changes: 16 additions & 0 deletions examples/pargs_penv.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::thread;
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_af_alg.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::errno::Errno;
use nix::sys::socket::{socket, AddressFamily, SockFlag, SockType};
use std::env;
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_epoll.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::fcntl::OFlag;
use nix::sys::epoll::{Epoll, EpollCreateFlags, EpollEvent, EpollFlags};
use nix::unistd::pipe2;
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_matrix.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::fcntl::{open, OFlag};
use nix::sys::epoll::{Epoll, EpollCreateFlags, EpollEvent, EpollFlags};
use nix::sys::eventfd::{EfdFlags, EventFd};
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_matrix_file_link.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::fcntl::{open, OFlag};
use nix::sys::stat::Mode;
use std::env;
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_matrix_unix_socket.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::thread;
Expand Down
16 changes: 16 additions & 0 deletions examples/pfiles_sockopts_parent.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::net::{TcpListener, UdpSocket};
Expand Down
16 changes: 16 additions & 0 deletions examples/plgrp_process.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::thread;
Expand Down
16 changes: 16 additions & 0 deletions examples/psig_signals.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::sys::signal::{pthread_sigmask, SigmaskHow};
use nix::sys::signal::{sigaction, SaFlags, SigAction, SigHandler, SigSet, Signal};
use std::env;
Expand Down
16 changes: 16 additions & 0 deletions examples/pstop_prun_process.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::thread;
Expand Down
16 changes: 16 additions & 0 deletions examples/ptree_parent_child.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::unistd::getppid;
use std::env;
use std::fs::File;
Expand Down
16 changes: 16 additions & 0 deletions examples/pwait_process.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::env;
use std::fs::File;
use std::thread;
Expand Down
16 changes: 16 additions & 0 deletions src/display.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

//! Shared formatting helpers for process data.
//!
//! This module formats environment variables, auxiliary vectors, and
Expand Down
16 changes: 16 additions & 0 deletions src/proc/auxv.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use std::collections::HashSet;
use std::fs::File;
use std::io::Read;
Expand Down
16 changes: 16 additions & 0 deletions src/proc/cred.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
//
// Copyright 2026 Basil Crow
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//

use nix::libc;

use super::Error;
Expand Down
Loading
Loading