×ðÁú¿­Ê±¹ÙÍøµÇ¼

linux getÏÂÁîÔõôÓÃ

get ÏÂÁîÓÃÓÚÔÚ linux ÖлñÈ¡ºÍÉèÖÃϵͳ±äÁ¿µÄÖµ£¨°üÀ¨ÇéÐαäÁ¿£©£¬ÌṩÒÔϹ¦Ð§£º»ñÈ¡±äÁ¿Öµ¡£ÉèÖñäÁ¿Öµ£¨½ö¶ÔÄ¿½ñ»á»°ÓÐÓã©¡£ÒÔÐÐÁбíÐÎʽÁгöËùÓÐÇéÐαäÁ¿¼°ÆäÖµ¡£

Linux get ÏÂÁÓ÷¨ÓëʾÀý

get ÏÂÁîÓÃÓÚÔÚ Linux ÖлñÈ¡ºÍÉèÖÃϵͳ±äÁ¿µÄÖµ¡£Ëüͨ¹ýʹÓõײãµÄÇéÐαäÁ¿ºÍÉèÖÃÎļþÀ´ÊµÏִ˹¦Ð§¡£

Ó÷¨£º

get [Ñ¡Ïî] ±äÁ¿Ãû

Ñ¡Ï

-h£ºÏÔʾ×ÊÖúÐÅÏ¢¡£

-s£º´Ë±ê¼ÇÒÖÖƱê×¼Êä³ö£¬½ö·µ»Ø±äÁ¿Öµ¡£

-p£º»ñÈ¡±äÁ¿Öµ²¢½«Æä´òÓ¡µ½±ê×¼Êä³ö¡£

-l£ºÒÔÐÐÁбíµÄÐÎʽÁгöËùÓÐÇéÐαäÁ¿¼°ÆäÖµ¡£

ʾÀý£º

1. »ñÈ¡±äÁ¿Öµ£º

$ get USER
demo

µÇ¼ºó¸´ÖÆ

2. »ñÈ¡±äÁ¿Öµ²¢´òÓ¡µ½±ê×¼Êä³ö£º

$ get -p USER
demo

µÇ¼ºó¸´ÖÆ

3. ÒÔÐÐÁбíÐÎʽÁгöÇéÐαäÁ¿£º

$ get -l
LANG=en_US.UTF-8
USER=demo
HOME=/home/demo

µÇ¼ºó¸´ÖÆ

4. ÉèÖñäÁ¿Öµ£º

ËäÈ» get ÏÂÁîÖ÷ÒªÓÃÓÚ»ñÈ¡±äÁ¿Öµ£¬µ«ËüÒ²¿ÉÒÔʹÓà -s Ñ¡ÏîÉèÖñäÁ¿Öµ¡£

$ get -s USER="new_user"

µÇ¼ºó¸´ÖÆ

×¢ÖØ£º

get ÏÂÁî²Ù×÷ÇéÐαäÁ¿£¬¶ø²»ÊÇÉèÖÃÎļþ¡£

ʹÓà -s Ñ¡ÏîÉèÖñäÁ¿ÖµÊ±£¬¸Ã¸ü¸Ä½ö¶ÔÄ¿½ñ»á»°ÓÐÓá£ÒªÓÀÊÀ¸ü¸Ä±äÁ¿Öµ£¬Çë±à¼­ÏìÓ¦µÄÉèÖÃÎļþ£¨ÀýÈç /etc/environment£©¡£

get ÏÂÁî¿ÉÒÔÓëÆäËûÏÂÁîÍŽáʹÓã¬ÀýÈç grep »ò awk£¬ÒÔ´¦ÀíºÍ¹ýÂ˱äÁ¿Öµ¡£

ÒÔÉϾÍÊÇlinux getÏÂÁîÔõôÓõÄÏêϸÄÚÈÝ£¬¸ü¶àÇë¹Ø×¢±¾ÍøÄÚÆäËüÏà¹ØÎÄÕ£¡

ÃâÔð˵Ã÷£ºÒÔÉÏչʾÄÚÈÝȪԴÓÚÏàÖúýÌå¡¢ÆóÒµ»ú¹¹¡¢ÍøÓÑÌṩ»òÍøÂçÍøÂçÕûÀí£¬°æȨÕùÒéÓë±¾Õ¾Î޹أ¬ÎÄÕÂÉæ¼°¿´·¨Óë¿´·¨²»´ú±í×ðÁú¿­Ê±¹ÙÍøµÇ¼ÂËÓÍ»úÍø¹Ù·½Ì¬¶È£¬Çë¶ÁÕß½ö×ö²Î¿¼¡£±¾ÎĽӴýתÔØ£¬×ªÔØÇë˵Ã÷À´ÓÉ¡£ÈôÄúÒÔΪ±¾ÎÄÇÖÕ¼ÁËÄúµÄ°æȨÐÅÏ¢£¬»òÄú·¢Ã÷¸ÃÄÚÈÝÓÐÈκÎÉæ¼°ÓÐÎ¥¹«µÂ¡¢Ã°·¸Ö´·¨µÈÎ¥·¨ÐÅÏ¢£¬ÇëÄúÁ¬Ã¦ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼ʵʱÐÞÕý»òɾ³ý¡£

Ïà¹ØÐÂÎÅ

ÁªÏµ×ðÁú¿­Ê±¹ÙÍøµÇ¼

18523999891

¿É΢ÐÅÔÚÏß×Éѯ

ÊÂÇéʱ¼ä£ºÖÜÒ»ÖÁÖÜÎ壬9:30-18:30£¬½ÚãåÈÕÐÝÏ¢

QR code
ÍøÕ¾µØͼ