diff options
author | BlackNoxis <steven.darklight@gmail.com> | 2015-06-24 10:49:24 +0300 |
---|---|---|
committer | BlackNoxis <steven.darklight@gmail.com> | 2015-06-24 10:49:24 +0300 |
commit | 3f3eb088770626f5798e801e40404e6336f8628e (patch) | |
tree | 3c0b74e38fa6fd7bc3848f7ca833d2de878c27e3 /app-editors | |
parent | bb4950d106d7822165480e9fd358c819fd56cc75 (diff) |
[sublime-text] added sublime
Diffstat (limited to 'app-editors')
-rw-r--r-- | app-editors/sublime-text/Manifest | 2 | ||||
-rw-r--r-- | app-editors/sublime-text/sublime-text-3083.ebuild | 87 |
2 files changed, 89 insertions, 0 deletions
diff --git a/app-editors/sublime-text/Manifest b/app-editors/sublime-text/Manifest new file mode 100644 index 00000000..c4aafbae --- /dev/null +++ b/app-editors/sublime-text/Manifest @@ -0,0 +1,2 @@ +DIST sublime_text_3_build_3083_x32.tar.bz2 7572911 SHA256 89e8e2bafa041c263d2c5ffd1b8ea3c36d9727c95a3f7a6603bdf1f6c4cc3165 SHA512 7329e689d0a212bb8ac255f05845b3dfb94f0c60d4d7e9b3445c390c9ae13d2a63e7df9385b1a2a7ff38cf5bce7151d51a4a482d94e2712684db7055dc78502f WHIRLPOOL 2d9f81480d75169e4e7dd6e7081dce9705c17347dba4e6579a6643b79a30d06589db21173a7ca33db352706067324103edebd5d5eb42d8f10a35c5754c0bb75a +DIST sublime_text_3_build_3083_x64.tar.bz2 7505310 SHA256 4565c7f607b69ca6efa1751c739a11d42aeaf66d15987fbb9595e97e3ece14ee SHA512 a92c2ce4aa2e99d1c77cf65a8da8539d907bf28ea6190488d97e632c501f7d38182b8d6eec831387505fab61f7d0449de2797bc4f947a9198a2b0bc1280df386 WHIRLPOOL 00f01e3249600acd9eece42a6ee3a9b9421aac4546ade1130a835e13e559ba92978b2efab44af4ce472310173568bf40b4c48e16512f264c249faf569ce8b344 diff --git a/app-editors/sublime-text/sublime-text-3083.ebuild b/app-editors/sublime-text/sublime-text-3083.ebuild new file mode 100644 index 00000000..0e2b70d9 --- /dev/null +++ b/app-editors/sublime-text/sublime-text-3083.ebuild @@ -0,0 +1,87 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI=5 +inherit eutils gnome2-utils + +# get the major version from PV +MV="${PV:0:1}" + +MY_PN="sublime_text_${MV}" +MY_P="Sublime%20Text" +S="${WORKDIR}/${MY_PN}" + +DESCRIPTION="Sophisticated text editor for code, markup and prose" +HOMEPAGE="http://www.sublimetext.com" + +BASE_URI="http://c758482.r82.cf2.rackcdn.com" +SRC_URI="amd64? ( ${BASE_URI}/${MY_PN}_build_${PV}_x64.tar.bz2 ) + x86? ( ${BASE_URI}/${MY_PN}_build_${PV}_x32.tar.bz2 )" +LICENSE="Sublime" +SLOT="${MV}" +KEYWORDS="~amd64 ~x86" +IUSE="multislot dbus" +RESTRICT="bindist mirror strip" + +DEPEND=">=media-libs/libpng-1.2.46 + >=x11-libs/gtk+-2.24.8-r1:2 + multislot? ( app-admin/eselect-sublime ) + dbus? ( sys-apps/dbus )" +RDEPEND="${DEPEND}" + +QA_PREBUILT="*" + +pkg_nofetch() { + eerror "Sublime Text official site seems to be unresponsive." +} + +src_install() { + insinto /opt/${MY_PN} + into /opt/${MY_PN} + exeinto /opt/${MY_PN} + doins -r "Icon" + doins -r "Packages" + doins "python3.3.zip" + doins "sublime.py" + doins "sublime_plugin.py" + doexe "sublime_text" + doexe "plugin_host" + dosym "/opt/${MY_PN}/sublime_text" /usr/bin/subl${MV} + + local size + for size in 16 32 48 128 256 ; do + insinto /usr/share/icons/hicolor/${size}x${size}/apps + newins "Icon/${size}x${size}/sublime-text.png" sublime_text.png + done + + make_desktop_entry "subl${MV} %F" "Sublime Text ${MV}" sublime_text "Development;TextEditor" "StartupNotify=true" +} + +pkg_preinst() { + gnome2_icon_savelist +} + +pkg_postinst() { + gnome2_icon_cache_update + if use multislot; then + eselect_sublime_update + else + einfo "using major version ${MV} as default" + dosym /usr/bin/subl${MV} /usr/bin/subl + fi +} + +pkg_postrm() { + gnome2_icon_cache_update +} + +eselect_sublime_update() { + einfo + elog "Updating Sublime Text to the latest installed version" + elog "you can select the version you want to use just using" + elog + elog "eselect sublime set sublime_text_2" + einfo + eselect sublime set sublime_text_${MV} --use-old +} |