Cov txheej txheem:

SBT qhov project hauv Scala yog dab tsi?
SBT qhov project hauv Scala yog dab tsi?

Video: SBT qhov project hauv Scala yog dab tsi?

Video: SBT qhov project hauv Scala yog dab tsi?
Video: NFT Games Play To Earn 🔥 What is the Top Play-To-Earn Game? 2024, Lub peb hlis ntuj
Anonim

ua sbt yog ib qho qhib-qhov tsim cuab yeej rau Scala thiab Java tej yaam num , zoo ib yam li Java's Maven thiab Ant. Nws cov yam ntxwv tseem ceeb yog: Kev txhawb nqa haiv neeg rau kev sau Scala code thiab integrating nrog ntau Scala kuaj lub moj khaum. Nruam muab tso ua ke, sim, thiab xa mus.

Kuj nug, SBT txhais li cas?

SBT txhais tau tias "Sorry 'Bout That" Yog li tam sim no koj paub - SBT txhais tau tias "Thov txim 'Bout That" - tsis txhob ua tsaug rau peb. YW! Dab tsi ua SBT txhais tau tias ? SBT yog ib tug acronym, abbreviation los yog slang lo lus uas tau piav saum toj no qhov twg SBT txhais yog muab.

Tsis tas li ntawd, kuv yuav khiav SBT li cas? ua sbt plhaub muaj qhov hais kom ua (nrog tab ua tiav thiab keeb kwm!). Txhawm rau sau dua, nias lub xub thiab tom qab ntawd nkag mus. Rau khiav koj qhov program, hom khiav . Tawm mus ua sbt plhaub, ntaus tawm lossis siv Ctrl + D (Unix) lossis Ctrl + Z (Windows).

Ib sab ntawm no, kuv yuav ua li cas Scala qhov project?

Tsim qhov project

  1. Yog tias koj tsis tau tsim qhov project los ntawm kab hais kom ua, qhib IntelliJ thiab xaiv "Create New Project"
  2. Yog tias koj twb tau tsim qhov project ntawm kab hais kom ua, qhib IntelliJ, xaiv Import Project thiab qhib cov ntaub ntawv build.sbt rau koj qhov project.

Maven thiab SBT yog dab tsi?

Maven tso cai rau ib qhov project los tsim siv nws qhov project object model (POM) thiab ib pawg plugins uas tau muab los ntawm txhua qhov haujlwm siv Maven , muab ib tug uniform tsim system. Ntawm qhov tod tes, SBT yog cov ncauj lus kom ntxaws raws li "Ib qho qhib qhov cuab yeej tsim rau Scala thiab Java tej yaam num". Nws zoo ib yam li Java's Maven thiab Ant.

Pom zoo: