mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-22 06:23:19 -07:00
* debian/control, bin/*: remove dependencing on bc by using awk
This commit is contained in:
parent
ed54b2f414
commit
e915f15be4
4 changed files with 10 additions and 12 deletions
|
@ -1,8 +1,8 @@
|
||||||
#!/bin/sh -e
|
#!/bin/sh -e
|
||||||
|
|
||||||
mhz=`grep -m 1 "^cpu MHz" /proc/cpuinfo | sed "s/^.*: //" | sed "s/\..*$//"`
|
mhz=`grep -m 1 "^cpu MHz" /proc/cpuinfo | sed "s/^.*: //" | sed "s/\..*$//"`
|
||||||
if [ $mhz -gt 1000 -a -x /usr/bin/bc ]; then
|
if [ $mhz -ge 1000 ]; then
|
||||||
ghz=$(echo "scale=1; $mhz/1000" | bc)
|
ghz=$(echo "$mhz" | awk '{ printf "%.1f", $1 / 1000 }')
|
||||||
echo "$ghz""GHz"
|
echo "$ghz""GHz"
|
||||||
else
|
else
|
||||||
echo "$mhz""MHz"
|
echo "$mhz""MHz"
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
#!/bin/sh -e
|
#!/bin/sh -e
|
||||||
|
|
||||||
mem=`free | grep -m 1 "^Mem:" | awk '{print $2}'`
|
mem=`free | grep -m 1 "^Mem:" | awk '{print $2}'`
|
||||||
if [ $mem -gt 1000000 -a -x /usr/bin/bc ]; then
|
if [ $mem -ge 1048576 ]; then
|
||||||
mem=$(echo "scale=1; $mem/1000000" | bc)
|
mem=$(echo "$mem" | awk '{ printf "%.1f", $1 / 1048576 }')
|
||||||
echo "$mem""GB"
|
echo "$mem""GB"
|
||||||
elif [ $mem -gt 1000 -a -x /usr/bin/bc ]; then
|
elif [ $mem -ge 1024 ]; then
|
||||||
mem=$(echo "scale=0; $mem/1000" | bc)
|
mem=$(echo "$mem" | awk '{ printf "%.0f", $1 / 1024 }')
|
||||||
echo "$mem""MB"
|
echo "$mem""MB"
|
||||||
else
|
else
|
||||||
echo "$mem""KB"
|
echo "$mem""KB"
|
||||||
|
|
3
debian/changelog
vendored
3
debian/changelog
vendored
|
@ -5,8 +5,9 @@ screen-profiles (1.13) UNRELEASED; urgency=low
|
||||||
information
|
information
|
||||||
* doc/help.txt: updated help page
|
* doc/help.txt: updated help page
|
||||||
* keybindings/common: F12 -> lockscreen
|
* keybindings/common: F12 -> lockscreen
|
||||||
|
* debian/control, bin/*: remove dependencing on bc by using awk
|
||||||
|
|
||||||
-- Dustin Kirkland <kirkland@ubuntu.com> Thu, 22 Jan 2009 00:30:14 -0500
|
-- Dustin Kirkland <kirkland@ubuntu.com> Thu, 22 Jan 2009 00:31:23 -0500
|
||||||
|
|
||||||
screen-profiles (1.12-0ubuntu1) jaunty; urgency=low
|
screen-profiles (1.12-0ubuntu1) jaunty; urgency=low
|
||||||
|
|
||||||
|
|
7
debian/control
vendored
7
debian/control
vendored
|
@ -11,7 +11,6 @@ Package: screen-profiles
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Depends: ${misc:Depends}, debconf (>= 0.5) | debconf-2.0, screen, gettext-base, python, python-newt
|
Depends: ${misc:Depends}, debconf (>= 0.5) | debconf-2.0, screen, gettext-base, python, python-newt
|
||||||
Recommends: update-notifier-common
|
Recommends: update-notifier-common
|
||||||
Suggests: bc
|
|
||||||
Enhances: screen
|
Enhances: screen
|
||||||
Description: a set of useful profiles and a profile-switcher for GNU screen
|
Description: a set of useful profiles and a profile-switcher for GNU screen
|
||||||
screen-profiles includes a set of profiles for the GNU screen window manager.
|
screen-profiles includes a set of profiles for the GNU screen window manager.
|
||||||
|
@ -22,7 +21,5 @@ Description: a set of useful profiles and a profile-switcher for GNU screen
|
||||||
updates-available), etc. The profile-switcher allows users to quickly switch
|
updates-available), etc. The profile-switcher allows users to quickly switch
|
||||||
their .screenrc to any of the available profiles.
|
their .screenrc to any of the available profiles.
|
||||||
.
|
.
|
||||||
bc provides more advanced calculations of memory and cpu-speed in the
|
update-notifier-common provides a more efficient and standard mechanism for
|
||||||
status panel. update-notifier-common provides a more efficient and standard
|
calculating the number of updates available in the status panel.
|
||||||
mechanism for calculating the number of updates available in the status
|
|
||||||
panel.
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue