huhuhushan

简单的跟踪某网页特定内容的 shell

  •  
  •   huhuhushan · Mar 12, 2016 · 1223 views
    This topic created in 3744 days ago, the information mentioned may be changed or developed.
    #!/bin/bash
    
    url="http://v2ex.com"
    want="好玩"
    wget "$url" -O contents
    if
        result=$(cat contents | ack -i "$want")
    then
        echo "$result" | mail -s "Notification" [email protected]
    else
        echo "nothing"
    fi
    
    1 replies    2016-03-12 11:56:17 +08:00
    Strikeactor
        1
    Strikeactor  
       Mar 12, 2016
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3648 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 43ms · UTC 04:35 · PVG 12:35 · LAX 21:35 · JFK 00:35
    ♥ Do have faith in what you're doing.