Skip to content

Instantly share code, notes, and snippets.

View hardeep's full-sized avatar

Hardeep Shoker hardeep

View GitHub Profile
@hardeep
hardeep / question.md
Created February 19, 2020 01:33 — forked from rubenrivera/question.md
Question - Answer from Web Applications [Show URL used to edit responses from a Google Form in a Google Spreadsheet by using a script](http://webapps.stackexchange.com/q/89551/88163)

Revision 3 http://webapps.stackexchange.com/revisions/89551/3

Show URL used to edit responses from a Google Form in a Google Spreadsheet by using a script

I'm trying to make the edit URL for a Google Form automatically populate in the response Google Sheet that it's attached to. I've seen this already and want to use it, but I'm having issues trying to figure out where exactly to put the script.

I've tried putting it in the script editor in the Google Spreadsheet that I would like the URL to appear in, but I'm not sure where to go from there. In the script editor I've tried to test it as an add-on but that didn't end up working.

I have little experience with scripts and the script editor in Google Sheets. As a final note I am using one other add-on called AutoCrat in the same Google Spreadsheet.

@hardeep
hardeep / kafka.service
Created January 15, 2018 16:01 — forked from atrepca/kafka.service
Kafka Systemd Service Configuration File for Ubuntu 16.04
[Unit]
Description=Apache Kafka server (broker)
Documentation=http://kafka.apache.org/documentation.html
Requires=network.target remote-fs.target
After=network.target remote-fs.target
[Service]
Type=simple
PIDFile=/var/run/kafka.pid
User=kafka
@hardeep
hardeep / gulpfile.js
Created January 7, 2016 21:29
Gulpfile.js for transpiling ES6 to ES5 using babel.
const gulp = require("gulp");
const sourcemaps = require("gulp-sourcemaps");
const babel = require("gulp-babel");
const notify = require("gulp-notify");
const packageJson = require("./package.json");
gulp.task('build', function() {
return gulp.src('src/**/*.js')
.pipe(sourcemaps.init())
.pipe(babel(packageJson.babel))
virtualbox-iso: update-alternatives: using /usr/lib/x86_64-linux-gnu/libtxc_dxtn_s2tc.so.0 to provide /usr/lib/x86_64-linux-gnu/libtxc_dxtn.so (libtxc-dxtn-x86_64-linux-gnu) in auto mode
2014/04/15 18:54:30 ui: virtualbox-iso: update-alternatives: using /usr/lib/x86_64-linux-gnu/libtxc_dxtn_s2tc.so.0 to provide /usr/lib/x86_64-linux-gnu/libtxc_dxtn.so (libtxc-dxtn-x86_64-linux-gnu) in auto mode
virtualbox-iso: Setting up curl (7.32.0-1ubuntu1.4) ...
2014/04/15 18:54:30 ui: virtualbox-iso: Setting up curl (7.32.0-1ubuntu1.4) ...
virtualbox-iso: Setting up liberror-perl (0.17-1) ...
2014/04/15 18:54:30 ui: virtualbox-iso: Setting up liberror-perl (0.17-1) ...
virtualbox-iso: Setting up git-man (1:1.8.3.2-1) ...
2014/04/15 18:54:30 ui: virtualbox-iso: Setting up git-man (1:1.8.3.2-1) ...
virtualbox-iso: Setting up git (1:1.8.3.2-1) ...
2014/04/15 18:54:30 ui: virtualbox-iso: Setting up git (1:1.8.3.2-1) ...
@hardeep
hardeep / gist:4727488
Created February 7, 2013 01:05
Android 2.2.0 with SDK 17
Hardeeps-MacBook-Air:2.2.0 hardeep$ bin/create ~/Desktop/app com.example.www "app"Updated project.properties
Updated local.properties
build.xml: Found version-tag: custom. File will not be updated.
Updated file /Users/shardeep/build/gimlet/vendor/android/2.2.0/framework/proguard-project.txt
It seems that there are sub-projects. If you want to update them
please use the --subprojects parameter.
Buildfile: /Users/shardeep/build/gimlet/vendor/android/2.2.0/framework/build.xml
-check-env:
[checkenv] Android SDK Tools Revision 21.0.1
@hardeep
hardeep / record_sha
Created September 6, 2012 23:43
record and compare shas
# current repo directory
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
DIRS="$( echo $DIR | sed 's/[^a-zA-Z0-9]/_/g' )"
# current branch
CBRANCH="$(git symbolic-ref -q HEAD)"
# current branch as a safe name
CSBRANCH="$(echo $CBRANCH | sed 's/[^a-zA-Z0-9]/_/g')"
@hardeep
hardeep / gist:3544178
Created August 30, 2012 23:03
hydra-log-1
08-26 21:48:19.970: W/dalvikvm(2306): VFY: unable to resolve direct method 288: Landroid/webkit/WebView;.<init> (Landroid/content/Context;Landroid/util/AttributeSet;IZ)V
08-26 21:48:20.000: I/webclipboard(2306): clipservice: android.sec.clipboard.ClipboardExManager@40528d30
08-26 21:48:20.030: I/CordovaLog(2306): Changing log level to DEBUG(3)
08-26 21:48:20.030: I/CordovaLog(2306): Found preference for useBrowserHistory=false
08-26 21:48:20.030: D/CordovaLog(2306): Found preference for useBrowserHistory=false
08-26 21:48:20.030: I/CordovaLog(2306): Found preference for fullscreen=false
08-26 21:48:20.030: D/CordovaLog(2306): Found preference for fullscreen=false
08-26 21:48:20.030: D/CordovaWebView(2306): Origin to allow: http://127.0.0.1*
08-26 21:48:20.040: E/dalvikvm(2306): Could not find class 'android.webkit.WebResourceResponse', referenced from method org.apache.cordova.CordovaWebViewClient.generateWebResourceResponse
08-26 21:48:20.040: W/dalvikvm(2306): VFY: unable to resolve new-instance 107 (Landro