æ¬æ ŒçãªPythonã¢ããªã±ãŒã·ã§ã³ãäœæããå¿
èŠã¯ãããŸããã ãããã顧客ã«ãããã販売ãããããã«äœæ¥ãµãŒãã¹ããã°ããçµã¿ç«ãŠãŸã-ãªãã§ããïŒ Pythonã¯æ®éçã§ããããã®èšèªã§ã¢ãã€ã«ãœãããŠã§ã¢ãäœæããçµéšã圹ç«ã€å ŽåããããŸãã Sberbankã®Vladislav Shashkovã¯ãkivyãã¬ãŒã ã¯ãŒã¯ã䜿çšããŠéçºãã©ã®ããã«éçºãããŠãããã«ã€ããŠè©±ããŸããã
-ããã«ã¡ã¯ã ç§ã®ååã¯Vladislav Shashkovã§ããç§ã¯Sberbankã§åããŠããŸããå®éãç§ã¯é£æååºã§ãããéçºè
ã§ã¯ãããŸããã Pythonã§ã¢ãã€ã«ã¢ããªã±ãŒã·ã§ã³ãäœæããããšã¯éåžžã«ç°¡åã§ããããšãæ確ã«ç€ºããããããã¯ç§ã®ã¬ããŒãã«èå³ããããããããŸããã
Kivy-çµå±ã圌ã¯ãKiwiãã§ãããªããªãã圌ã¯å®ç©ã®åœ¢ã§æ¬ã®è¡šçŽã«æ¯figçã«æãããŠããããã·ã¢èªã§ã¯ãKiwiãã®çºé³ãããè¿ããªãããã§ãã ãã®ãã¬ãŒã ã¯ãŒã¯ã¯2011幎ããéçºãããŠããŸãã å®éãããã¯ãã¢ãã€ã«ãã©ãããã©ãŒã ã ãã§ãªããã¯ãã¹ãã©ãããã©ãŒã ã¢ããªã±ãŒã·ã§ã³ãäœæããããã®ã°ã©ãã£ã«ã«UIã©ã€ãã©ãªã§ãã ãã®æ©èœã¯KVèšèªã§ãããããŒã¯ã¢ããèšèªã§ãã KVèšèªãšã¯äœããæ¯figçã«èª¬æããããšãããšãHTMLãPythonã§æžãããŠããå ŽåãHTMLã¯æ¬¡ã®ããã«ãªããŸãã
ãŸãããããªã¢ã«ãã¶ã€ã³ã¹ã¿ã€ã«ã®äžé£ã®ãŠã£ãžã§ããã§ããKivyMDã©ã€ãã©ãªã«ã€ããŠã説æããŸãã KivyMDã䜿çšãããšããŠãŒã¶ãŒãšã¯ã¹ããªãšã³ã¹ãæäœã§ãã䜿ããããGoogleã€ã³ã¿ãŒãã§ãŒã¹ãäœæã§ããŸãã
ãã®ãããªã§ã¯ ãã©ã€ãã©ãªå
ã®ãã¹ãŠã®ãŠã£ãžã§ãããã©ã®ããã«ã¹ã¯ããŒã«ããããã
瀺ããŠããŸãã ã芧ã®ãšãããããã¯ããªãè±å¯ãªèŠçŽ ã®ã»ããã§ãã ãããã¯ãããã¯ããŒã¯ããã¿ã³ãé²è¡ç¶æ³ããŒãããã³ãããã¢ããã§ãã åºæ¬çã«ãå¿
èŠãªã«ã¹ã¿ããŒãšã¯ã¹ããªãšã³ã¹ãå®çŸããããã«å¿
èŠãªãã®ã¯ãã¹ãŠæã£ãŠããŸãã iOSã§ã¢ã»ã³ããªãçµã¿ç«ãŠãå¿
èŠãããå Žåã¯ããŸã£ããåãããã«èŠããŸãã åãææèšèšã ååãšããŠããã®ãããªã¢ããªã±ãŒã·ã§ã³ã¯App Storeã§å
¬éã§ããŸãããGoogleã«äŒŒãŠããŸãã
KivyMDã䜿çšããªãKivyã¯ãéåžžã«å³æ Œãªãã¶ã€ã³ã§ãã 顧客ã«ãèŠããŠã¯ãããŸããã Ubuntã®ã·ã³ãã«ãªãã¿ã³ãã¢ãã€ã«ãšã¯ã¹ããªãšã³ã¹ã«é©åããªãã·ã³ãã«ãªãã€ã¢ãã°ãã¢ãã€ã«ãŠãŒã¶ãŒã«äŒŒãŠããŸãã ãããŠãKivyMDã¯ããã§ããŠããŠããã¹ãŠãçŸããã§ããŠããŸãã
ããã€ãã®æªããã¥ãŒã¹ããããŸãã å®è¡å¯èœãªã¢ããªã±ãŒã·ã§ã³ããã±ãŒãžã¯ãç¹å¥ãªãŠãŒãã£ãªãã£buildozerã«ãã£ãŠã¢ã»ã³ãã«ãããŸãã æªããã¥ãŒã¹ã¯ã䜿çšãéå§ããŠæåã®ã¢ã»ã³ããªãäœæããããšã¯ã決ããŠç°¡åã§ã¯ãªããšããããšã§ãã ããããããã¹ãŠã®ãªãŒãã³ãœãŒã¹ãœãããŠã§ã¢ã§ã¯ããã¹ãŠãããŸãæ©èœããããã«ã¯ãæçµçã«ç®æšãéæããŠAPKãååŸããããã«ãç¹å®ã®ãéãããã©ãå¿
èŠããããŸãã
ãã®ã¹ã©ã€ãã§ã¯ãäœãããå¿
èŠãããããããã¹ãããã©ãéããŠããŸãããéããªãæ¹æ³ã«ã€ããŠè©³ãã説æããŠããŸãã kivyèªäœãŸãã¯ã€ã¡ãŒãžå
ã®ä»ã®ã©ã€ãã©ãªãæŽæ°ããããšããªãã§ãã ããã å¿
èŠãªãã®ã¯ãã¹ãŠã¹ã©ã€ãã«ç€ºãããŠãããæ®ãã¯è¿œãã€ããŠåäœããŸãã
次ã«ãKivyãããžã§ã¯ãã®æ§é ã«ã€ããŠå°ãã話ããŸãã ã¹ã©ã€ãã«ã¯ãGitHubãžã®ãªã³ã¯ããšã³ã³ãŒããããQRã³ãŒãããããŸããããã«ãããããã«èªã¿ã説æããäŸãçŽæ¥ãã¬ãŒã¹ã§ããŸãã ïŒ
æåã®ãªã³ã¯ -çŽç·šïŒ
buildozerä»æ§ãã¡ã€ã«ãç»é¢ã«è¡šç€ºãããŸããããã¯ãããžã§ã¯ãã®ä»æ§ã§ãã ããã§æãéèŠãªããšã¯ãèŠä»¶ãã€ãŸãã¢ã»ã³ããªã«å¿
èŠãªã©ã€ãã©ãªããªã¹ãããè¡ãããããã®äžã«KivyãKivyMDãæå®ããå¿
èŠããããããã«ã¬ã³ãŒãããããGitHubã§ãå©çšã§ããããšã§ãã
éèŠãªã»ã¯ã·ã§ã³ã¯ã³ã¡ã³ãã¢ãŠããããŠãããAndroid NDKãSDKã«é¢ä¿ããã®ã§ã觊ããå¿
èŠã¯ãããŸããã ããã©ã«ãå€ãæ©èœããŸãã
UIãšUXã«ã€ããŠå°ãã KVããŒã¯ã¢ããèšèªã«ã¯ããŠã£ãžã§ãããšã¬ã€ã¢ãŠããšãã2ã€ã®æŠå¿µããããŸãã ãŠã£ãžã§ãã-衚瀺èŠçŽ ããã¿ã³ãå
¥åãã£ãŒã«ããªã©ã ãŠã£ãžã§ããã¯ã€ãã³ããåãåããããããåŠçã§ããŸãã ãŸããã¬ã€ã¢ãŠããšã¯ããŠã£ãžã§ãããé
眮ã§ãããªããžã§ã¯ãã®ããšã§ãããŠã£ãžã§ããã«ã¯ããŠã£ãžã§ãããäžåã«äžŠã¹ãããŸãã¯ãã®éãè¡ãããã®ããã€ãã®ã¿ã€ãããããäœããã®æ¹æ³ã§ä»»æã«é
眮ã§ããŸãã äžè¬ã«ããã®ã¢ãããŒãã¯ããžã¥ã¢ã«UIãUXã®æšæºã§ãããä»ã®ã©ã€ãã©ãªã§ã䜿çšãããŸãã
KVèšèªã®äŸã次ã«ç€ºããŸãïŒ
ãªã³ã¯ -çŽç·šïŒã ã芧ã®ããã«ãæåã«ã©ã€ãã©ãªã¯ããŒã®åŸãã«ã€ã³ããŒãããã次ã«å±±æ¬åŒ§ã§ã€ã³ããŒããããŸã...ãã«ãŒãããšèšãã®ã¯ééã£ãŠããŸããæåã®ã¬ã€ã¢ãŠãã ãã§ãã¯ã©ã¹ãã³ãŒãã§ãããã³ã°ãããŸãã 1察1ã®ååãäžèŽããå¿
èŠããããŸãã ãããã£ãŠãããŒã¯ã¢ãããšã¯ã©ã¹ã¯ã³ãŒãå
ã§æ¯èŒãããŸãã ããã«ãã€ã³ãã³ãããããŠã£ãžã§ããã¯ã€ã³ãã³ããééãããŠã£ãžã§ããå
ã§ã¯ããããã£ãšã€ãã³ããåã³ã€ã³ãã³ããããåããªã¹ãã«è¿œå ãããŸãã ãµã³ãã«ã³ãŒãã次ã«ç€ºããŸãã
ã¯ã©ã¹ã®äžçªäžã«ããã®ã¯ã¬ã€ã¢ãŠãã¯ã©ã¹ã§ãã 次ã¯ã¢ããªã±ãŒã·ã§ã³ã¯ã©ã¹ã§ã以äžã¯ããŒã¯ã¢ããå®æ°ãèªã¿èŸŒãã§ã¢ããªã±ãŒã·ã§ã³ãèµ·åããããã®2è¡ã§ãã èŽè¡ã¯ããããã¢ãã€ã«éçºã«ããŸã粟éããŠããªãããšãç¥ã£ãŠããã®ã§ã次ã®ã¹ããããAPKãèµ·åããŠãããã°ããããã«é»è©±ã§äœãããå¿
èŠããããã«ã€ããŠèª¬æããŸãã
æåã®ã¹ãããã¯ãé»è©±ããªã³ã«ããŠéçºè
ã決å®ããããšã§ãã 圌ã¯éåžžã«å·§åŠã«ãªã³ã«ãªããŸãã éåžžãããã¯é»è©±èšå®ã¢ãŒãã§ã¡ãã¥ãŒé
ç®ãæŒãã·ãŒã¯ã¬ããã·ãŒã±ã³ã¹ã§ãã ãã¬ãŒã³ããŒã·ã§ã³ã«ã¯äžè¬çãªã·ãŒã±ã³ã¹ã®1ã€ã衚瀺ãããŸãããã䜿ãã®æºåž¯é»è©±ã§ã¯æ©èœããªãå ŽåããããŸãã ãã®äžé£ã®ã¢ã¯ã·ã§ã³ãå®äºãããšãéçºè
åãã®ã¢ãŒãã衚瀺ãããŸããAPKãæ¢ã«ã€ã³ã¹ããŒã«ãããããã°ããŠãåäœãç¶è¡ã§ããŸãã
Buildozerã¯ä»®æ³ãã·ã³ã§å®è¡ãããŸããä»®æ³ãã·ã³ãæŽæ°ããã«ã¯ãä»®æ³ãã·ã³ãæŽæ°ããå¿
èŠããããŸãã ãã®åŸãUSBãšã®çµ±åã衚瀺ãããé»è©±ãä»®æ³ãã·ã³ã«æ¥ç¶ã§ããããã«ãªããŸãã
æ¥ç¶ãããããšã瀺ããµã€ã³-é»è©±ã¯ãããã°èš±å¯ãæ±ããŸãã ãããžã§ã¯ããã£ã¬ã¯ããªã¯ã/ BUILDãã©ã«ããŒã«äœæãããŸãã ãããžã§ã¯ãããã«ãããã«ã¯ããããžã§ã¯ããã£ã¬ã¯ããªã§buildozer android debugã³ãã³ããå®è¡ããå¿
èŠããããŸãã é»è©±æ©ãžã®APKã®ã€ã³ã¹ããŒã«ã¯ããã§ã«ç»åã«å«ãŸããŠããAndroid Studioã®ãŠãŒãã£ãªãã£ã«ãã£ãŠãadb installã³ãã³ãã«ãã£ãŠå®è¡ãããŸãã
æåãšãããã¬ãŒãºã¯ããããŸã§ã®ãšãããé»è©±ãžã®ããŠã³ããŒããå®äºããããšã瀺ããŠããŸãã
ã³ãŒãã®ãããã°ã¯æ¬¡ã®ããã«å®è¡ãããŸãã ã³ã¬ã¯ã¿ãŒãã¢ããªã±ãŒã·ã§ã³ãšäžŠè¡ããŠåäœããããã«ãadb logcatã³ãã³ãã§ãããã°æ
å ±ã®åéãéå§ããå¿
èŠããããŸãã ãé«ã確çã§ãæåã®å®è¡åŸã®ã¢ããªã±ãŒã·ã§ã³ã¯ã¯ã©ãã·ã¥ããŸãããã®åŸããããã°ãåæ¢ããŠãã°ãã¡ã€ã«ãèªã¿èŸŒããŸãã
ãšã©ãŒã¡ãã»ãŒãžãæ€çŽ¢ããæ¹æ³ã¯ïŒ pythonããŒã¯ãŒãã«ããã pythonããŒã¯ãŒãã䜿çšããææ°ã®ãšã³ããªã¯ãéåžžãäœãééã£ãŠãããã瀺ããŸãã
é»è©±ã§ã§ããããšã«ã€ããŠã ã¢ãã€ã«ãã©ãããã©ãŒã ã䜿çšãããšãAPIã«ç§»åãããã¿ã³ã ãã§ãªããããŸããŸãªã¬ãžã§ããã»ã³ãµãŒãæäœã§ããŸãã ã¢ãã€ã«åšèŸºæ©åšãæäœããããã«ãæšæºã®ãã©ã€ã€ãŒã©ã€ãã©ãªããããŸãã ãã©ãããã©ãŒã ã«äŸåããŸãããã€ãŸããããã«æžãããŠãããã®ã¯ãã¹ãŠAndroidããiOSã«åæ§ç¯ãããŸãã ã¹ã©ã€ãã«ã¯ã䜿çšå¯èœãªãã¹ãŠã®ãªãã·ã§ã³ããªã¹ããããŠããŸãã GPSãããããªãŒãã«ã¡ã©ããããŸã...ããããã«ã¡ã©ãã©ã€ã€ãŒã䜿çšãããšãéæ¢ç»åã®ã¿ãæ®åœ±ã§ããŸãã
ãããŠã次ã®äŸã¯ãã®æ©äŒãæ¡å€§ããã ãã§ãã
GitHubãžã®ãªã³ã¯ ãã¢ããªã±ãŒã·ã§ã³ã§ãããªã¹ããªãŒã ãåä¿¡ã§ããäŸã§ãã åçããQRã³ãŒããèªèããããžãã¹ã¿ã¹ã¯ããããŸããã ãŸãããã®äŸã¯ããããªèªèãæ¡åŒµçŸå®ãªã©ã§æ©èœããŸãã
Kivyã«ã¯ãã«ã¹ã¿ã ã¢ããªã³çšã®ã¹ããŒã¹-GardenããããŸãã 誰ã§ããŠã£ãžã§ãããªã©ãå®è¡ã§ããŸãã ç§ã䜿çšãã䟿å©ãªãŠã£ãžã§ããã¯ããããã®æäœã§ãã 圌ã¯æŽ»åçã§ãå°å³ãæ¡å€§çž®å°ãã¹ãã³ã§ããŸãã æ¥ç¶æ¹æ³ã®äŸã次ã«ç€ºããŸãã Gardenã«ã¯ä»ã«ãå€ãã®ãŠã£ãžã§ããããããŸãã
ç§ããããžã§ã¯ãã«åãçµãã§ãããšããååãšåå»ãã¹ããå®æœããŠãã¢ããªã±ãŒã·ã§ã³ã®äœ¿çšã«é¢ãããã£ãŒãããã¯ãåéããŸããã ãããŠåœŒã¯ããç§ã¯å·Šã®APKãå
¥ããŸãããããããã¯ãããèš±å¯ããŸãããããé»è©±ãè²·ã£ãã°ããã§ãããªã©ã®çŽ æŽãããç°è°ãåãåããŸããã 顧客äœéšãæ¬è³ªçã«ãã¹ããç¶ããããã«ãã¢ãã€ã«ã¢ããªã±ãŒã·ã§ã³ãäœæããããã«ãã€ãŸãGoogle Playã§ãªãªãŒã¹ããããã«ããã¹ãŠã®æ¹æ³ã§è¡ããªããã°ãªããŸããã§ããã ã¹ã©ã€ãäžã«èšèŒãããŠããŸãã äž»ãªãã€ã³ãã¯ãããŒããããå¿
èŠããããGoogle Playã§ã®å
¬éã¯ç¡æã§ã¯ãªããšããããšã§ãã éçºè
ãšããŠç»é²ããã«ã¯ã25ãã«ãæºåããå¿
èŠããããŸãã Appleã¯99ãã«ãæ±ããŠããã®ã§ãããã¯ãŸã éåžžã«æ°äž»çã§ãã
ãã®ã¹ã©ã€ãã¯ããµã³ãã«ã¢ããªã±ãŒã·ã§ã³ãžã®
ãªã³ã¯ãæäŸããç§ã®ãããžã§ã¯ããèŠãããšãã§ããŸãã ããã¯ãŸã ã¢ã«ãã¡ãããã¿ã€ãã§ãã®ã§ãã¢ããªã±ãŒã·ã§ã³ãã¯ã©ãã·ã¥ãããã©ãããå³å¯ã«å€æããªãã§ãã ããã çŸåšã®ããã¥ã¡ã³ããž
ã®ãªã³ã¯ã¯æ°é®®ã§ãç§ã«ã¯è¯ãããã§ãã
VKontakteã°ã«ãŒããšããã³ãã¥ããã£ããã
ãHabréã®ç®¡çè
ãå®æçã«èšäºãçºè¡ããŠããŸãã