#!/usr/bin/env ruby require 'optparse' check_comments = false historical_import = false options = {} choices = OptionParser.new do |opts| opts.banner = "Usage: linkedin_orbit --check-comments" opts.on("-h", "--help", "Prints help instructions") do puts opts exit end opts.on("--check-comments", "Check for new LinkedIn comments") do check_comments = true end opts.on("--historical-import", "Performa historical import of all LinkedIn interactions") do historical_import = true end end.parse! $LOAD_PATH.unshift(File.expand_path('../lib/dev_orbit', __dir__)) require_relative '../lib/linkedin_orbit' require_relative '../scripts/check_comments' if check_comments puts "Checking for new LinkedIn comments and posting them to your Orbit workspace..." ARGV[0] = 'render' ARGV[1] = historical_import LinkedinOrbit::Scripts::CheckComments.start(ARGV) end