Ib qho ntawm feem ntau nthuav nrhav nyob rau hauv lub qhov rais 10, uas tus neeg siv nruab nrab yuav tsis pom, PackageManagement's built-in pack manager (yav dhau los OneGet), uas ua kom yooj yim rau nruab, nrhiav, thiab tswj lwm qhov kev pab cuam hauv koj lub computer. Nws yog hais txog kev txhim kho cov kev pab cuam los ntawm cov kab hais kom ua, thiab yog tias koj tsis meej meej txog qhov nws yog thiab vim li cas nws yuav pab tau, kuv xav kom pib saib cov yees duab tom kawg ntawm txoj kev qhia no.
Hloov tshiab 2016: tus manager-built-in pob tau hu ua OneGet nyob rau theem ntawm qhov ua ntu zus ntawm qhov rais 10, tam sim no nws yog lub pob PackageManagement module hauv PowerShell. Tsis tas li ntawd nyob rau hauv phau ntawv tshiab txoj kev siv nws.
PackageManagement yog ib qho tseem ceeb ntawm PowerShell nyob rau hauv Qhov rai 10; dhau li ntawd, koj tuaj yeem tau txais ib pob haujlwm los ntawm kev txhim kho qhov kev tswj xyuas qhov rais hauv Windows 8.1. Tsab ntawv xov xwm no yog ob peb qhov piv txwv ntawm kev siv lub npav pob rau tus neeg siv coj zoo, nrog rau txoj kev txuas mus rau lub chaw cia khoom (ib yam ntawm cov ntaub ntawv khaws cia) Chocolatey nyob rau hauv PackageManagement (Chocolatey yog tus thawj tswj lub pob uas koj siv tau rau hauv Windows XP, 7 thiab 8 software repository. Kawm ntau ntxiv txog kev siv Chocolatey ua tus thawj tswj lub npav ywj siab.
PackageManagement Commands hauv PowerShell
Siv feem ntau ntawm cov lus txib hauv qab no, koj yuav tsum khiav qhov rais PowerShell ua tus thawj coj.
Ua li no, pib ntaus ntawv PowerShell hauv kev tshawb xyuas cov haujlwm, ces nias qhov kev tshwm sim thiab xaiv "Run as Administrator".
Cov Thawj Saib Xyuas Cov Khoom Siv los sis Kev Tswj Management OneGet tso cai rau koj ua haujlwm nrog cov kev pabcuam (nruab, uninstall, nrhiav, hloov tshiab yog tsis tau muab) hauv PowerShell siv cov kev cai tsim nyog - kev zoo sib xws yog cov paub cov neeg siv Linux. Yuav kom tau txais ib lub tswv yim ntawm qhov tau hais, koj tuaj yeem saib qhov screenshot hauv qab no.
Qhov zoo ntawm txoj kev txhim kho cov haujlwm no yog:
- siv qhov tseeb qhov software (koj tsis tas yuav manually tshawb rau lub vas sab),
- tsis muaj installation ntawm lub tshuab uas yuav tsum tau tsis pub lub tshuab thaum nruab (thiab feem ntau txheej txheem kev paub nrog cov "Tom ntej" khawm),
- muaj peev xwm los tsim cov ntawv sau (piv txwv, yog tias koj xav tau los nruab ib qhov txheej txheem ntawm lub computer tshiab los yog tom qab rov nruab rau qhov rais, koj tsis tas yuav manually download tau thiab nruab lawv, cia li khiav tsab ntawv),
- raws li yooj yim ntawm installation thiab kev tswj software ntawm cov cav tov tej thaj chaw deb (rau cov thawj coj).
Koj tuaj yeem tau txais ib daim ntawv teev cov lus txib muaj nyob rau hauv PackageManagement siv Mus Txuas-Txav -Module PackageManagement Cov tseem ceeb rau cov neeg siv yooj yim yuav:
- Nrhiav Pob-nrhiav - nrhiav ib pob (program), piv txwv: Nrhiav Pob-Npe VLC (lub npe parameter yuav rho tawm, cov ntaub ntawv ntawm cov tsiaj ntawv tsis tseem ceeb).
- Nruab-Pob - tso qhov kev pab cuam ntawm lub computer
- Uninstall-pob - uninstall kev pab cuam
- Tau pob-saib - ntsia cov pob khoom ntsia
Cov lus txib ntxiv yog npaj rau saib cov chaw ntawm pob (cov kev pabcuam), lawv ntxiv thiab tshem tawm. Lub sijhawm no tseem ceeb heev rau peb.
Ntxiv Chocolatey Repository mus rau PackageManagement (OneGet)
Tsis tas li ntawd, nyob rau hauv qhov chaw tos khoom (pre-installed repositories) (qhov chaw pabcuam) uas PackageManagement ua haujlwm, muaj tsawg me ntsis, tshwj xeeb tshaj yog thaum nws tuaj yeem ua lag luam (tab sis tsis pub) - Google Chrome, Skype, ntau cov ntawv thov kev pab thiab cov nqi hluav taws xob.
Microsoft lub neej tso kev tsim kho ntawm NuGet repository muaj kev tsim cov cuab yeej rau cov neeg tsim cai, tab sis tsis rau kuv cov neeg nyeem ntawv nyeem (los ntawm txoj kev, thaum ua haujlwm nrog PackageManagement, koj tuaj yeem tau muab rau nruab ib lub tuam txhab NuGet, kuv tsis tau pom ib txoj kev kom tshem tau nws tshwj tsis yog pom zoo ib zaug nrog installation).
Txawm li cas los xij, qhov teeb meem yuav daws tau los ntawm kev sib txuas ntawm Chocolatey pob manager tus thawj tswj xyuas kom ua tau, siv qhov kev hais kom ua:
Get-PackageProvider -Name chocolatey
Tshawb xyuas qhov kev txhim kho ntawm Chocolatey tus tswv muag khoom, thiab tom qab muab nkag rau qhov kev txiav txim:
Npaj-Pob -Source -Name chocolatey - muab tso tawm
Ua li cas.
Qhov kawg tshaj plaws uas yuav tsum tau txhaj rau lub pob khoom chocolatey yuav tsum tau muab kho yog qhov kev hloov ntawm Txoj Cai-Txoj Cai. Kom hloov, sau cov lus txib kom cia tag nrho cov peev xwm ntseeg tau cog lus PowerShell khiav los:
Teem-ExecutionPolicy RemoteSigned
Lo lus txib cia rau kev siv cov ntawv sau tau kos npe los ntawm hauv Internet.
Txij ntawm no, cov pob khoom ntawm Chocolatey repository yuav ua hauj lwm hauv PackageManagement (OneGet). Yog hais tias tsis tshwm sim thaum lub sij hawm teeb meem, sim siv cov parameter -Tsis yog.
Thiab tam sim no ib qho piv txwv ntawm kev siv PackageManagement nrog ib tus kws kho mob Chocolatey.
- Piv txwv li, peb yuav tsum tau txhim kho qhov kev pab dawb hauv Paint.net (nws yuav yog lwm txoj kev pabcuam dawb, feem ntau ntawm cov kev pabcuam dawb yog nyob hauv chaw cia khoom). Sau pawg nrhiav-pob-npe xim (Koj tuaj yeem nkag mus lub npe ntawm ib ntus, yog tias koj tsis paub lub npe ntawm lub pob, lub npe "npe" tsis raug tseev kom muaj).
- Vim li ntawd, peb pom tias paint.net nyob hauv lub chaw cia khoom. Rau nruab, siv qhov kev hais kom ua nruab-pob-name paint.net (peb siv lub npe pes tsawg ntawm sab laug sab).
- Peb tos rau lub installation kom tiav thiab tau txais qhov kev pabcuam uas tau ntsia, tsis nrhiav qhov twg los mus download tau nws thiab tsis tau txais ib qho software pliaj hauv koj lub computer.
Yees duab - Siv Package Manager Manager Package (aka OneGet) los txhim kho software hauv Windows 10
Zoo, nyob rau hauv xaus - txhua yam yog tib yam, tab sis nyob rau hauv video hom, nws yuav yooj yim rau qee cov nyeem kom to taub tias qhov no yog tseem ceeb rau nws los yog tsis.
Rau lub sijhawm ua, peb yuav pom tias qhov kev ua haujlwm pob yuav zoo li yav tom ntej: muaj cov ntaub ntawv hais txog qhov kev pom ntawm OneGet graphical interface thiab kev txhawb rau kev siv duab los tom khw qhov rais thiab lwm yam kev zeem muag rau qhov khoom.