Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 221899 | Differences between
and this patch

Collapse All | Expand All

(-)a/rails-1.2.6.ebuild (-1 / +6 lines)
Lines 34-48 Link Here
34
	# Rename slotted files that may clash so that eselect can handle
34
	# Rename slotted files that may clash so that eselect can handle
35
	# them
35
	# them
36
	mv ${D}/usr/bin/rails ${D}/usr/bin/rails-${PV}
36
	mv ${D}/usr/bin/rails ${D}/usr/bin/rails-${PV}
37
	sed -i -e "s/>= 0/${PV}/" "${D}/usr/bin/rails-${PV}"
37
	mv ${D}/${GEMSDIR}/bin/rails ${D}/${GEMSDIR}/bin/rails-${PV}
38
	mv ${D}/${GEMSDIR}/bin/rails ${D}/${GEMSDIR}/bin/rails-${PV}
38
}
39
}
39
40
40
pkg_postinst() {
41
pkg_postinst() {
41
	einfo "To select between slots of rails, use:"
42
	einfo "To select between slots of rails, use:"
42
	einfo "\teselect rails"
43
	einfo "\teselect rails"
43
	eselect rails update --if-unset
44
	eselect rails update
44
}
45
}
45
46
46
pkg_postrm() {
47
pkg_postrm() {
47
	eselect rails update --if-unset
48
	eselect rails update --if-unset
49
	if [ -n "`eselect rails list` | grep 'none found'" ]; then
50
		rm -f /usr/bin/rails
51
	fi
52
	eselect rails update
48
}
53
}
(-)a/rails-2.0.5.ebuild (-4 / +7 lines)
Lines 30-48 Link Here
30
	# Rename slotted files that may clash so that eselect can handle
30
	# Rename slotted files that may clash so that eselect can handle
31
	# them
31
	# them
32
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
32
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
33
	sed -i -e "s/>= 0/${PV}/" "${D}/usr/bin/rails-${PV}"
33
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
34
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
34
}
35
}
35
36
36
pkg_postinst() {
37
pkg_postinst() {
37
	einfo "To select between slots of rails, use:"
38
	einfo "To select between slots of rails, use:"
38
	einfo "\teselect rails"
39
	einfo "\teselect rails"
39
	# Bring users to rails 2.0.x by default when updating
40
	eselect rails update
40
	eselect rails update 2
41
41
42
	ewarn "All database USE flags have been moved to dev-ruby/activerecord"
42
	ewarn "All database USE flags have been moved to dev-ruby/activerecord"
43
}
43
}
44
44
45
pkg_postrm() {
45
pkg_postrm() {
46
	# Drop users back to rails 1.2.x when they remove 2.0.x
46
	eselect rails update --if-unset
47
	eselect rails update 1.2
47
	if [ -n "`eselect rails list` | grep 'none found'" ]; then
48
		rm -f /usr/bin/rails
49
	fi
50
	eselect rails update
48
}
51
}
(-)a/rails-2.1.2.ebuild (-4 / +6 lines)
Lines 30-48 Link Here
30
	# Rename slotted files that may clash so that eselect can handle
30
	# Rename slotted files that may clash so that eselect can handle
31
	# them
31
	# them
32
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
32
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
33
	sed -i -e "s/>= 0/${PV}/" "${D}/usr/bin/rails-${PV}"
33
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
34
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
34
}
35
}
35
36
36
pkg_postinst() {
37
pkg_postinst() {
37
	einfo "To select between slots of rails, use:"
38
	einfo "To select between slots of rails, use:"
38
	einfo "\teselect rails"
39
	einfo "\teselect rails"
39
	# Bring users to rails 2.1.x by default when updating
40
	eselect rails update
40
	eselect rails update 2.1
41
41
42
	ewarn "All database USE flags have been moved to dev-ruby/activerecord"
42
	ewarn "All database USE flags have been moved to dev-ruby/activerecord"
43
}
43
}
44
44
45
pkg_postrm() {
45
pkg_postrm() {
46
	# Drop users back to rails 2.0.x when they remove 2.1.x
46
	if [ -n "`eselect rails list` | grep 'none found'" ]; then
47
	eselect rails update 2
47
		rm -f /usr/bin/rails
48
	fi
49
	eselect rails update
48
}
50
}
(-)a/rails-2.2.2.ebuild (-4 / +6 lines)
Lines 29-45 Link Here
29
	# Rename slotted files that may clash so that eselect can handle
29
	# Rename slotted files that may clash so that eselect can handle
30
	# them
30
	# them
31
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
31
	mv "${D}/usr/bin/rails" "${D}/usr/bin/rails-${PV}"
32
	sed -i -e "s/>= 0/${PV}/" "${D}/usr/bin/rails-${PV}"	
32
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
33
	mv "${D}/${GEMSDIR}/bin/rails" "${D}/${GEMSDIR}/bin/rails-${PV}"
33
}
34
}
34
35
35
pkg_postinst() {
36
pkg_postinst() {
36
	einfo "To select between slots of rails, use:"
37
	einfo "To select between slots of rails, use:"
37
	einfo "\teselect rails"
38
	einfo "\teselect rails"
38
	# Bring users to rails 2.2.x by default when updating
39
	eselect rails update
39
	eselect rails update 2.2
40
}
40
}
41
41
42
pkg_postrm() {
42
pkg_postrm() {
43
	# Drop users back to rails 2.1.x when they remove 2.2.x
43
	if [ -n "`eselect rails list` | grep 'none found'" ]; then
44
	eselect rails update 2.1
44
		rm -f /usr/bin/rails
45
	fi
46
	eselect rails update
45
}
47
}

Return to bug 221899