Comment 175 for bug 509180

Revision history for this message
Plouj (plouj) wrote :

Actually the script in comment #173 so here is a better version:

#!/bin/bash

# Matches decrypted files in the home directory to empty files in the
# underlying encrypted directory by inode number. Limits search to the
# CWD sub-directories.

echo "saving inodes of empty files to /tmp/empty-encrypted-inodes"
# Fake Inode 0 is used to make construction of arguments easier
find . -xdev -inum 0 $(
    for inode in $(find $HOME/.Private/ -xdev -size 0c -exec ls -ai '{}' \;|awk '{print $1}'|tee /tmp/empty-encrypted-inodes); do
        echo -n " -o -inum $inode"
    done)