Gruntfile.js: 'dist' task to create directory for distribution

When distributing the extension, we want to ship only the files we
need to run it.

BUG=None
TEST=Loaded unpacked extension and manually tested it worked

Change-Id: I867fbe9fd0003ac2daf7b740162fcd2b86631d0a
diff --git a/Gruntfile.js b/Gruntfile.js
index 7e30242..2b0e7c3 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -55,6 +55,35 @@
     }
   });
 
+  grunt.registerTask('dist', 'Create distribution directory', function() {
+    let outDir = 'dist';
+    [
+      'android_state_graph.js',
+      'androidlog_summary.js',
+      'background.js',
+      'lib/d3.min.js',
+      'lib/inflate.js',
+      'lib/zip.js',
+      'listnr_content_script.js',
+      'log_helper.js',
+      'log_summary.js',
+      'manager.js',
+      'manifest.json',
+      'netlog_summary.js',
+      'popup.js',
+      'process_log.js',
+      'service.js',
+      'service_states.html',
+      'service_summary.css',
+      'state_graph.js',
+      'syslog_summary.js',
+      'wifi_icon.png',
+      'wifi_state_machine.js',
+    ].forEach(filename => {
+      grunt.file.copy(filename, outDir + '/' + filename);
+    });
+  });
+
   grunt.registerTask('default', ['copy']);
 
 };