def run(self, edit, browser=None):
		print("View In Browser plugin v{0}, Python {1}".format(PLUGIN_VERSION, self._pythonVersion))

		#
		# Load plugin settings and project settings, if any. A project settings may
		# affect the file to open based on local server
		# environment settings.
		#
		pluginSettings = self.loadPluginSettings(browser)
		projectSettings = self.loadProjectSettings(self.view)

		fileToOpen = self.view.file_name()

		#
		# If we've specified settings for a local server environment
		# use them
		#
		if projectSettings:
			fileToOpen = self.giveFileAProjectPath(fileToOpen, projectSettings["basePath"], projectSettings["baseUrl"])

		#
		# If the current view has not been saved, put it into
		# a temp file and open that instead. If the view
		# DOES have a name make sure it is save before
		# opening.
		#
		if fileToOpen == None:
			fileToOpen = self.normalizePath(self.saveCurrentViewInTempFile(self.view))

		else:
			if self.view.is_dirty():
				print("File %s is dirty. Saving..." % (fileToOpen,))
				self.view.window().run_command("save")

			if not projectSettings:
				fileToOpen = self.normalizePath(fileToOpen)

		#
		# And open. If the settings file contains a valid selected browser use that
		# command to open this file. Otherwise use the system default.
		#
		if pluginSettings["baseCommand"]:
			command = "%s %s" % (pluginSettings["baseCommand"], fileToOpen.decode().encode(sys.getfilesystemencoding()) if self._pythonVersion < 3 else fileToOpen,)

			print(command)
			self.openBrowser(command, self.getOsName())

		else:
			if self._pythonVersion < 3:
				webbrowser.open_new_tab(fileToOpen.encode(sys.getfilesystemencoding()))
			else:
				webbrowser.open_new_tab(fileToOpen)
dataset/ETHPy150Open adampresley/sublime-view-in-browser/ViewInBrowserCommand.py/ViewInBrowserCommand.run/original