Tag Info

New answers tagged

2

Grep exits by default with 0 on match and 1 on no match. As such you could do: grep -q "targed file \$1 is patched sucesfully, enjoy new kernel" foo.log The -q suppress any output. To test say something like: grep -q "targed file \$1 is patched sucesfully, enjoy new kernel" foo.log && echo OK || echo BAD If the $1 is actually replaced with a ...


1

grep is the way to go, it returns 0 if a match is found. You don't actually need to output the line, so just discard the line and use the test. In your case, it would just be lastline=$(tail -n1 logfile) if grep pattern <<<"$lastline" &>/dev/null; then echo "yay, found pattern" else echo "darn" fi Observe the "here string" ...


1

Lets see what the kernel configs looks like: cat /boot/config-$(uname -r) | grep CONFIG_USB_ETH Output: bob@bob-NE722:~/Downloads/odoo-8.0$ cat /boot/config-$(uname -r) | grep CONFIG_USB_ETH CONFIG_USB_ETH=m CONFIG_USB_ETH_RNDIS=y CONFIG_USB_ETH_EEM=y This indicates that compiled into the ubuntu kernel is support for RNDIS and EEM, but usb ethernet ...


2

There must be a modified bootloader. A good example is the HTC HD2, a phone that can run Windows Mobile 6.5, Android, Meego, Ubuntu, Firefox OS and Windows Phone. It is possible because someone developed a bootloader called MAGLDR that let the user install new OSs and choose in which one start the system.


2

Yes and no. Yes, you can (usually) take older source code and combine it with newer one. That is what for example CyanogenMod is doing (apart from other things). No, you can't decompile the built image, extract sources, drop those verbatim into newer sources and recompile. It's just not that simple, for couple of reasons, mainly: Decompilation is just ...


0

You can use this simple command to turn off the display xset dpms force off And to turn on the display you can pass on instead of off. UPDATE: If your screen is not turned off after executing this command then DPMS(display power management signalling) is not enabled in your system.You can enable that by following command xset +dpms Method 2 First ...



Top 50 recent answers are included