feat: migrate to golang
This commit is contained in:
16
internal/subscription/ctime_linux.go
Normal file
16
internal/subscription/ctime_linux.go
Normal file
@ -0,0 +1,16 @@
|
||||
//go:build linux
|
||||
|
||||
package subscription
|
||||
|
||||
import (
|
||||
"os"
|
||||
"time"
|
||||
)
|
||||
|
||||
// creationTime returns the file's modification time on Linux, since
|
||||
// birthtime isn't reliably exposed by the kernel/filesystem. This mirrors
|
||||
// the Python version's own fallback (st_ctime) when st_birthtime is
|
||||
// unavailable (subscription_manager.py:273-278).
|
||||
func creationTime(info os.FileInfo) time.Time {
|
||||
return info.ModTime()
|
||||
}
|
||||
Reference in New Issue
Block a user