Created
April 19, 2014 02:13
-
-
Save jnakatsui/11071722 to your computer and use it in GitHub Desktop.
list ppa on *nix system
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
# listppa Script to get all the PPA installed on a system ready to share for reininstall | |
for APT in `find /etc/apt/ -name \*.list`; do | |
grep -o "^deb http://ppa.launchpad.net/[a-z0-9\-]\+/[a-z0-9\-]\+" $APT | while read ENTRY ; do | |
USER=`echo $ENTRY | cut -d/ -f4` | |
PPA=`echo $ENTRY | cut -d/ -f5` | |
echo sudo apt-add-repository ppa:$USER/$PPA | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment