Skip to content

Instantly share code, notes, and snippets.


Guljar Prasad guljarpd

  • Rivi
  • Bengaluru, India
View GitHub Profile
sabarasaba / gist:3080590
Created Jul 10, 2012
Remove directory from remote repository after adding them to .gitignore
View gist:3080590
git rm -r --cached node_modules
git commit -m 'Remove the now ignored directory node_modules'
git push origin master
gerard-kanters / inactivity.js
Last active Apr 2, 2021
Inactivity timeout javascript
View inactivity.js
<script type="text/javascript">
function idleTimer() {
var t;
//window.onload = resetTimer;
window.onmousemove = resetTimer; // catches mouse movements
window.onmousedown = resetTimer; // catches mouse movements
window.onclick = resetTimer; // catches mouse clicks
window.onscroll = resetTimer; // catches scrolling
window.onkeypress = resetTimer; //catches keyboard actions