mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-01-11 03:11:50 +00:00
Extend PublishedStorage interface for Acquire-By-Hash
Signed-off-by: André Roth <neolynx@gmail.com>
This commit is contained in:
committed by
Oliver Sauder
parent
bb2db7e500
commit
e07912770e
@@ -264,3 +264,27 @@ func (storage *PublishedStorage) RenameFile(oldName, newName string) error {
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// SymLink creates a symbolic link, which can be read with ReadLink
|
||||
func (storage *PublishedStorage) SymLink(src string, dst string) error {
|
||||
// TODO: create a file containing dst
|
||||
return fmt.Errorf("SWIFT: symlinks not implemented")
|
||||
}
|
||||
|
||||
// HardLink creates a hardlink of a file
|
||||
func (storage *PublishedStorage) HardLink(src string, dst string) error {
|
||||
// TODO: create a copy of the file
|
||||
return fmt.Errorf("SWIFT: hardlinks not implemented")
|
||||
}
|
||||
|
||||
// FileExists returns true if path exists
|
||||
func (storage *PublishedStorage) FileExists(path string) bool {
|
||||
// TODO: implement
|
||||
return false
|
||||
}
|
||||
|
||||
// ReadLink returns the symbolic link pointed to by path
|
||||
func (storage *PublishedStorage) ReadLink(path string) (string, error) {
|
||||
// TODO: read the path and return the content of the file
|
||||
return "", fmt.Errorf("SWIFT: ReadLink not implemented")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user