Categories: Uncategorized

XBMC irexec start python script

Azonos terminálból indítva (display :0-ból):

# Test to see if XBMC is running first

if pidof -s /usr/share/xbmc/xbmc.bin ; then
 # Try a clean kill
 echo "Closing xbmc!"
 ps aux|grep -i tv|grep -v grep|grep -i xbmc.bin|awk '{print $2}'|xargs kill
 echo "XBMC stoped (soft)"
 # takes a second or two to die with the soft kill
 sleep 2
 if pidof -s /usr/share/xbmc/xbmc.bin ; then
  ps aux|grep -i tv|grep -v grep|grep -i xbmc.bin|awk '{print $2}'|xargs kill -9
  echo "XBMC stoped (hard)"
 else 
  echo "XBMC Stoped (soft)"
 fi
else
 echo "Startup XBMC"
 xbmc
fi

echo "Done!"

Másik terminálból indítva (display :0-ra indítva):

# Test to see if XBMC is running first

if pidof -s /usr/share/xbmc/xbmc.bin ; then
   # Try a clean kill
   echo "Closing xbmc!"
   ps aux|grep -v grep|grep -i xbmc.bin|awk '{print $2}'|xargs kill
   echo "XBMC stopped (soft)"
   # takes a second or two to die with the soft kill
   sleep 2
   if pidof -s /usr/share/xbmc/xbmc.bin ; then
      ps aux|grep -v grep|grep -i xbmc.bin|awk '{print $2}'|xargs kill -9
      echo "XBMC stopped (hard)"
   else 
      echo "XBMC stopped (soft)"
   fi  
else
   echo "Startup XBMC"
   DISPLAY=:0 xbmc &
fi

echo "Done!"
ronhks

Recent Posts

Mac TimeMachine drive on Samba share

First, create a Samba share on the easiest way. For example, mine: [macbook-pro-14] path =…

2 years ago

oh-my-zsh p10k git branch name shortened

I use this and I experiened like this: The branch name is shortened and can't…

2 years ago

Intellij IDEA Golang own package problem

I really like IDEA for developing. I worked on a golang project and I organised…

2 years ago

Run MiniDLNA from docker

For reusage: docker run -d \-p 8200:8200 \--restart=on-failure:3 \--name minidlna \-v /opt/minidlna/cache:/minidlna/cache \-v /mnt/data/series:/media/series \-v…

2 years ago

Docker img ipv6 problem

On my host the ipv6 is disabled. I had to start a docker image, which…

3 years ago

Gentoo USB serial passthrough KVM

I have a Conbee II Zigbee receiver. After a restart the USB passthrought stopped working…

3 years ago

This website uses cookies.