@@ -30,9 +30,9 @@ module.exports = (grunt) ->
|
||||
rm rpmDir
|
||||
mkdir rpmDir
|
||||
|
||||
installDir = grunt.config.get('atom.installDir')
|
||||
installDir = '/usr'
|
||||
shareDir = path.join(installDir, 'share', 'atom')
|
||||
iconName = path.join(shareDir, 'resources', 'app', 'resources', 'atom.png')
|
||||
iconName = 'atom'
|
||||
|
||||
data = {name, version, description, installDir, iconName}
|
||||
specFilePath = fillTemplate(path.join('resources', 'linux', 'redhat', 'atom.spec'), data)
|
||||
|
||||
@@ -21,7 +21,7 @@ Ubuntu LTS 12.04 64-bit is the recommended platform.
|
||||
|
||||
### Fedora / CentOS / RHEL
|
||||
|
||||
* `sudo yum --assumeyes install make gcc gcc-c++ glibc-devel git-core libgnome-keyring-devel rpmdevtools`
|
||||
* `sudo yum --assumeyes install make gcc gcc-c++ glibc-devel git-core libgnome-keyring-devel rpmdevtools ImageMagick`
|
||||
* Instructions for [Node.js](https://github.com/joyent/node/wiki/Installing-Node.js-via-package-manager#fedora).
|
||||
|
||||
### Arch
|
||||
@@ -35,7 +35,7 @@ Ubuntu LTS 12.04 64-bit is the recommended platform.
|
||||
|
||||
### openSUSE
|
||||
|
||||
* `sudo zypper install nodejs make gcc gcc-c++ glibc-devel git-core libgnome-keyring-devel rpmdevtools`
|
||||
* `sudo zypper install nodejs make gcc gcc-c++ glibc-devel git-core libgnome-keyring-devel rpmdevtools ImageMagick`
|
||||
|
||||
## Instructions
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
Name=Atom
|
||||
Comment=<%= description %>
|
||||
GenericName=Text Editor
|
||||
Exec=<%= installDir %>/share/atom/atom %U
|
||||
Exec=atom %U
|
||||
Icon=<%= iconName %>
|
||||
Type=Application
|
||||
StartupNotify=true
|
||||
|
||||
BIN
resources/linux/icons/1024.png
Normal file
|
After Width: | Height: | Size: 628 KiB |
BIN
resources/linux/icons/128.png
Normal file
|
After Width: | Height: | Size: 20 KiB |
BIN
resources/linux/icons/16.png
Normal file
|
After Width: | Height: | Size: 944 B |
BIN
resources/linux/icons/24.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
BIN
resources/linux/icons/256.png
Normal file
|
After Width: | Height: | Size: 61 KiB |
BIN
resources/linux/icons/32.png
Normal file
|
After Width: | Height: | Size: 2.4 KiB |
BIN
resources/linux/icons/48.png
Normal file
|
After Width: | Height: | Size: 4.5 KiB |
BIN
resources/linux/icons/512.png
Normal file
|
After Width: | Height: | Size: 192 KiB |
BIN
resources/linux/icons/64.png
Normal file
|
After Width: | Height: | Size: 7.0 KiB |
@@ -5,23 +5,31 @@ Summary: Atom is a hackable text editor for the 21st century
|
||||
License: MIT
|
||||
URL: https://atom.io/
|
||||
AutoReqProv: no # Avoid libchromiumcontent.so missing dependency
|
||||
Prefix: /usr/local
|
||||
Prefix: /usr
|
||||
|
||||
%description
|
||||
<%= description %>
|
||||
|
||||
%install
|
||||
mkdir -p %{buildroot}/usr/local/share/atom
|
||||
cp -r /tmp/atom-build/Atom/* %{buildroot}/usr/local/share/atom
|
||||
mkdir -p %{buildroot}/usr/local/bin/
|
||||
ln -sf ../share/atom/resources/app/apm/node_modules/.bin/apm %{buildroot}/usr/local/bin/apm
|
||||
cp atom.sh %{buildroot}/usr/local/bin/atom
|
||||
chmod 755 atom.sh
|
||||
mkdir -p %{buildroot}/usr/local/share/applications/
|
||||
mv atom.desktop %{buildroot}/usr/local/share/applications/
|
||||
mkdir -p %{buildroot}/usr/share/atom
|
||||
cp -r Atom/* %{buildroot}/usr/share/atom
|
||||
mkdir -p %{buildroot}/usr/bin/
|
||||
ln -sf ../share/atom/resources/app/apm/node_modules/.bin/apm %{buildroot}/usr/bin/apm
|
||||
cp atom.sh %{buildroot}/usr/bin/atom
|
||||
chmod 755 %{buildroot}/usr/bin/atom
|
||||
mkdir -p %{buildroot}/usr/share/applications/
|
||||
cp atom.desktop %{buildroot}/usr/share/applications/
|
||||
|
||||
# use imagemagick to create icons in sizes that most desktop environments like
|
||||
for i in 512x512 256x256 64x64 48x48 32x32 24x24 22x22 16x16
|
||||
do
|
||||
mkdir -p %{buildroot}/usr/share/icons/hicolor/${i}/apps
|
||||
convert Atom/resources/app/resources/atom.png -resize ${i} %{buildroot}/usr/share/icons/hicolor/${i}/apps/atom.png
|
||||
done
|
||||
|
||||
%files
|
||||
/usr/local/bin/atom
|
||||
/usr/local/bin/apm
|
||||
/usr/local/share/atom/
|
||||
/usr/local/share/applications/atom.desktop
|
||||
/usr/bin/atom
|
||||
/usr/bin/apm
|
||||
/usr/share/atom/
|
||||
/usr/share/applications/atom.desktop
|
||||
/usr/share/icons/hicolor/
|
||||
|
||||
@@ -11,7 +11,7 @@ ARCH=`uname -m`
|
||||
|
||||
rpmdev-setuptree
|
||||
|
||||
cp -r $BUILD_DIRECTORY/Atom/* $RPM_BUILD_ROOT/BUILD
|
||||
cp -r $BUILD_DIRECTORY/Atom $RPM_BUILD_ROOT/BUILD
|
||||
cp $SPEC_FILE $RPM_BUILD_ROOT/SPECS
|
||||
cp ./atom.sh $RPM_BUILD_ROOT/BUILD
|
||||
cp $DESKTOP_FILE $RPM_BUILD_ROOT/BUILD
|
||||
|
||||