â»ãã®è¨äºã¯ãSpeee Advent Calendar23æ¥ç®ã®è¨äºã§ãã æ¨æ¥ã®è¨äºã¯ãã¡ã tech.speee.jp ã©ãããæè¿ã¯å°ãgraphql-rubyã¨æ¯ãã¦ããç³äºã§ãã ã¿ãªãããgraphql-rubyã使ã£ã¦ãã¦ããã®Typeã®ãã®ãã£ã¼ã«ãã¯Adminã¦ã¼ã¶ã«ããè¦ããããªããã§ãï¼ãã¨ãã£ãããã«ã¢ã¯ã»ã¹å¶éããããªãæã3æ¥ã«1åãããã¯ãã£ã¦æ¥ãã®ã§ã¯ãªãã§ããããã ä»åã¯Railsã¨graphql-rubyã§APIãä½ãéã«graphql-guardã使ã£ã¦ã·ã³ãã«ãªã¢ã¯ã»ã¹å¶éãå®ç¾ããæ¹æ³ãã½ã¼ã¹ã³ã¼ããç¹ã交ãã¤ã¤ç´¹ä»ãã¦ã¿ããã¨æãã¾ãã â»æ¬è¨äºã§è¨è¼ããã³ã¼ãã¯å ¨ã¦å®è£ ã®é°å²æ°ãä¼ãããã¨ãç®çã®ãµã³ãã«ã³ã¼ããªã®ã§ãäºæ¿ãã ããã æ³å®ããç°å¢ ãã®è¨äºã§ã¯ä¸è¨ã®ãã¼ã¸ã§ã³ã®è¨èªãã©ã¤ãã©ãªã®å©ç¨ãæ³å®ãã¦ãã¾ãã Ruby: 2.7.5
ããã«ã¡ã¯ãid:r7kamura ã§ããæ¥åå§è¨ã¨ããå½¢ã§1å¹´ã»ã©é¢ãããªãããç¾å®¹ã®ã¯ãã³ããµã¼ãã¹LIPSã«å©ç¨ãã¦ããRuby on Rails (以ä¸Rails) ã¨ããWebã¢ããªã±ã¼ã·ã§ã³ãã¬ã¼ã ã¯ã¼ã¯ã®ãã¼ã¸ã§ã³ãã4.2ãã6.1ã«ä¸ãã¾ããã Rails 4.2ã®ãªãªã¼ã¹ã¯2014å¹´ãRails 6.1ã®ãªãªã¼ã¹ã¯2020å¹´ãªã®ã§ãããã6å¹´åã®ãã¼ã¸ã§ã³ã¢ãããä¸æ°ã«æ¨ãé²ãããã¨ã«ãªãã¾ãã ä»åã¯ãããé¡æã«ããã®æã®ãã¬ã¼ã ã¯ã¼ã¯ã®ãã¼ã¸ã§ã³ã¢ããæã«èµ·ãããã¡ãªè«¸åé¡ãããã£ã¦è¯ãã£ããã¨æªãã£ããã¨çã«ã¤ãã¦æ¯ãè¿ããã¨æãã¾ãã ãã¾ãRailsã«éã£ã話ã¯ããªãããã«å¿æãã¦æ¸ããã®ã§ããããã£ããã¼ã¸ã§ã³ã¢ããä½æ¥ã«èå³ãããæ¹ã«ã¯ãã²èªãã§ãã£ã¦ããããã°ã¨æãã¾ãã å¤æ´ã®ç²åº¦ãªã© ã¬ãã¥ã¼ã®ããæ¹ è¤æ°ãã¼ã¿ãã¼ã¹å¯¾å¿ã§å°ã£ã話 ãã¹ãããªãã¦å°
Caution ãã®è¨äºã¯DHHãã¡ã³ã®å¦æ³ã«ããã·ããªãªãå¤åã«å«ã¾ãã¾ãã ã¨ãããã»ã¨ãã©ã§ãã æãç«ã¡ãééã£ã¦ããã¨ãå½ç¶ããããã«æãã®ã§è©±ååã§èªãã§ãã ããã ããã¯ä¸ä½ æè¿ã®Railsããã³ãã¨ã³ããDHHã®æ´»åã«ã¯ä¸é£ã®æµããããããã§ãããä¸é¨ãã¬ã³ãã«æ²¿ã£ã¦ãªãé¨åãããæ ã«ãããæ±²ããªãã¨ããã¨ãããããã®ã§ã¯ã¨æãã¾ãã ãããã®æµããè¨æ¶ãå®ããªãã¡ã«ã¤ãªãã§è¨é²ãã¦ãããã¨ããè¨äºã§ãã åæç¥è Railsã®çã¿ã®è¦ªãRubyist Basecamp(社) DHHãCTOãã£ã¦ãä¼ç¤¾ Basecamp(ãµã¼ãã¹) Basecamp(社)ãéçºãã¦ãããã¸ã§ã¯ã管çãã¼ã« Trixãéçºãã¦ãããæ¥ Basecamp(ãµã¼ãã¹)ã«çµã¿è¾¼ã¾ãã¦ããªããããã¹ãã¨ãã£ã¿ã®trixãcustomElements使ã£ã¦éçºãã¦ãããæ¥ãDHHã¯ãããã¨ã«æ°ã¥ãã
September 6, 2021 Rails 7 will have three great answers to JavaScript in 2021+ Rails has been unapologetically full stack since the beginning. We've continuously sought to include ever-more default answers to all the major infrastructure questions posed by modern web development. From talking to a database, to sending and receiving emails, to connecting web sockets, to rendering HTML, to integrati
Product { this.openCategory = category; const productMenu = document.querySelector('.product-menu'); window.DD_RUM.onReady(function() { if (productMenu.classList.contains('show')) { window.DD_RUM.addAction(`Product Category ${category} Hover`) } }) }, 160); }, clearCategory() { clearTimeout(this.timeoutID); } }" x-init=" const menu = document.querySelector('.product-menu'); var observer = new Muta
Batteries includedCrystalâs standard library comes with a whole range of libraries that let you start working on your project right away. Check the API docs # A very basic HTTP server require "http/server" server = HTTP::Server.new do |context| context.response.content_type = "text/plain" context.response.print "Hello world, got #{context.request.path}!" end address = server.bind_tcp(8080) puts "L
English version è¦ç´ dockerã¯ããã©ã«ãã§ã»ãã¥ãªãã£æ©æ§ï¼Spectreèå¼±æ§ã®å¯¾çï¼ãæå¹ã«ãã¾ãããã®å½±é¿ã§ãRubyãPythonã®ãããªã¤ã³ã¿ããªã¿ã¯é度ãå£åãã¾ããç¹ã«CPUå¾éãªããã°ã©ã ã§é¡èã«é ããªãã¾ãï¼å®è¡æéãåãããã«ãªããã¨ãããã¾ãï¼ã ç¾è±¡ Rubyã§1ååã«ã¼ãããã³ã¼ãããç´æ¥ãã¹ãä¸ã§å®è¡ããå ´åã¨ãdockerä¸ã§å®è¡ããå ´åã§å®è¡æéãæ¯è¼ãã¦ã¿ã¾ãã ç´æ¥ãã¹ãä¸ã§å®è¡ããå ´åï¼ $ ruby -ve 't = Time.now; i=0;while i<100_000_000;i+=1;end; puts "#{ Time.now - t } sec"' ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) [x86_64-linux] 1.321703922 sec docker
åç (3件ä¸ã®1件ç®) Rubyã®å®è¡é度ã«èå³ããã£ã¦ã15å¹´ãããMRIã®éçºããã¦ãã¾ããèå³ãããã®ã§é·ãè¨äºã«ãªã£ã¡ãã£ããã¨ããè©«ã³ãã¾ãã é ãã¨è¨ã£ãã¨ããå¤åãå®è¡é度ãã®è©±ããã¦ãããã ã¨æãã¾ããããã以å¤ã«ãçµæ§ããããªãã¯ããããããã¾ããæãã¤ãã¨ããã§å°ããç´¹ä»ãã¾ãã (1) ããã°ã©ã ãä½ãã¯ãã Ruby ã¯çç£æ§ãé«ãè¨èªã¨è¨ããããã¨ãå¤ãã®ã§ãããã°ã©ã ãä½ãæ©ãã¯æ©ããã¨ããè©ä¾¡ãä¸è¬çã§ãã Cã§æ¸ãã¨2æ¥ããããå®è¡æéã¯0.1ç§ Rubyã§æ¸ãã¨1æ¥ããããå®è¡æéã¯10ç§ï¼Cã®100åï¼ ã¨ãããã極端ãªä»®å®ãç½®ãã¦ã¿ãã¨...
ããã«ã¡ã¯ãJapanTaxi SREãã¼ã ã®æ°´æ¸ã§ãã ã¤ã³ãã©ããã¢ããªã±ã¼ã·ã§ã³ã¾ã§ãµã¼ãã¹ã®å®å®æ§åä¸ã®ããã®æ¹åãæ¥ã è¡ã£ã¦ãã¾ãã ä»å¹´9æã®ãªãã¥ã¼ã¢ã«ã§ãJapanTaxiã¢ããªåãã®APIã«GraphQLãå°å ¥ãã¾ããããã®è¨äºã§ã¯å®éã«GraphQLå°å ¥ãããã¨ã§æããã¡ãªããã¨èª²é¡ãæ¸ãã¦ããããã¨æãã¾ãã ç¾å¨ã®JapanTaxiã¢ããªã«ãããGraphQLã®å°å ¥ç¶æ³ ä»åã¯æ°å¹´ééçºãç¶ãã¦ããã¢ããªã®ãªãã¥ã¼ã¢ã«ããã¸ã§ã¯ãã¨ãããã¨ã§ãæ¢åé¨åã使ãã¾ããã¦ããé¨åãå¤ã ããå ¨ã¦ã®APIãä¸æã«ç½®ãæããã®ã¯é£ããç¶æ³ã§ããããã®ãããªãªã¼ã¹æç¹ã§ã¯ã¢ããªã®å¤æ´ã«åããã¦æ¹ä¿®ãå¿ è¦ã«ãªã£ãåç §ç³»ã®APIã«ã®ã¿GraphQLãå°å ¥ãã¾ããã ãªãªã¼ã¹å¾ã¯é 次RESTããGraphQLã«åãæ¿ããé²ãã¦ãããä¸é¨ã§ã¯æ´æ°ç³»ã§ãGraphQLã使ãå§ãã¦ãã¾ãã
ãªã©ã¯ã«ãJavaãJavaScriptãRubyãPythonãªã©å¤è¨èªå¯¾å¿ãåä¸ã©ã³ã¿ã¤ã ã§å®ç¾ãããGraalVMãããªã¼ãã³ã½ã¼ã¹ã§å ¬éãTwitterãæ¬çªç°å¢ã§æ¡ç¨ JavaãJavaScriptãªã©ã«ã¯ããããããã®è¨èªãå®è¡ããããã®ã©ã³ã¿ã¤ã ãåå¨ãã¾ããJavaãªãJavaVMãJavaScriptãªãJavaScriptã¨ã³ã¸ã³ã¨ãã£ãå ·åã§ãã ç±³ãªã©ã¯ã«ããªã¼ãã³ã½ã¼ã¹ã§å ¬éãããGraalVMãã¯ãããã¾ã§è¨èªãã¨ã«åå¥ã«ç¨æããã¦ããã©ã³ã¿ã¤ã ãçµ±åããåä¸ã®é«æ§è½ãªVMã«ããã¨ããå社ã®ç 究ã®çµæéçºãããæ±ç¨ä»®æ³ãã·ã³ãããã¯æ±ç¨ã©ã³ã¿ã¤ã ã§ãï¼ç±³ãªã©ã¯ã«ã®ããã°ãæ¥æ¬èªè¨³ï¼ã GraalVMã®Webãµã¤ãã«ã¯ã次ã®ãããªèª¬æãè¨ããã¦ãã¾ãã GraalVM is a universal virtual machine for running appli
GraalVMã1.0.0 RC1ãåºããå ¬å¼ãµã¤ããå ¬éãã¾ããï¼ http://www.graalvm.org/ æ¥æ¬ã®æè¡ããã°ã¡ãã£ã¢Publickeyãããåãä¸ãã¦ãããã¾ãã www.publickey1.jp ãã®ãã¨ããã£ã¦ãGraalã§æ¤ç´¢ããã®ããã°ã¸ãã©ãçããæ¹ãå¤ãã£ãã§ããç§ã¯1å¹´ã»ã©åã0.23ã®é ããGraalVMã¨Graalï¼ä¸¡è ã®éãã¯å¾è¿°ï¼ã触ã£ã¦ãã¾ããï¼åã«è§¦ã£ã¦ããã ãã®1ãã¡ã³ã§ãï¼ãããããç±ççãªãã¡ã³ã®æ¹ã§ãJavaOneã§ã¯Graalã¨ãããã®ã¯å ¨ã»ãã·ã§ã³å ¥ãã¾ããããYouTubeã«ããä¸çã®æè¡ã«ã³ãã¡ã¬ã³ã¹åç»ã§Graalã«é¢ãããã®ã¯ãããããã¹ã¦è¦ã¦ãã¾ãã ãªã®ã§èªå·±æºè¶³ãã¦ãGraalVMã«ã¤ãã¦æ¸ãã¦ããã¾ãã GraalVMã£ã¦ä½ãªã®ï¼ 端çã«è¨ãã¨"Polyglot VM"ã§ããPolyglotã¨ã¯å¤è¨èªãæå³ã
ã¯ããã« æ©æ¢°å¦ç¿ãã¼ã ãªã©ã«ããã Python ã触ãå§ãã Rubyist ãå¢ãã¦ããã¨æãã¾ãããã®éã«åé¡ã«ãªããããã®ãç°å¢æ§ç¯ã§ããRubyã 㨠rbenv ãããã¡ã¯ãã¹ã¿ã³ãã¼ãã«ãªã£ã¦ããã®ã«ããªãã Python ã«ã¯ pyenv ã«å¦å®çãªæè¦ãå¤ããã§ãããã ç§ã¯ pyenv ã使ã£ã¦ãã¾ããã便å©ã ã¨æã£ã¦ãã¾ããã¾ãã Ruby ã¯æ®ã©ä½¿ããªãã®ã§ãããRubyã¨Pythonã®ãã¼ã«ã¹ã¿ãã¯ã®éãã«ã¤ãã¦ã調ã¹ã¾ããã (åè: gem, bundler 㨠pip, venv ã®æ¯è¼) ãã®è¦ç¹ããã Rubyã¦ã¼ã¶ã¼ãèªåã§pyenvã®ä½¿ãæ¹ãèªåã§æ±ºããä¸ã§ç¥ã£ã¦ãããæ¹ãè¯ãã ãããªã¨æã Ruby 㨠Python ã®ç°å¢ã®éããã¾ã¨ãã¦ã¿ã¾ãã tl;dr ä¸å¯§ã«è§£èª¬ãã¦ãããPython使ãã«ã¯ãããªé·ãè¨äºãèªã¾ãªãã¨ãããªãã®ãã¨ããã«å¦
(Last Updated On: 2018å¹´8æ13æ¥)åã®ã¨ã³ããªã§StackExchangeãReDoSã§æ»æãããµã¤ãããã¦ã³ããåé¡ãç´¹ä»ãã¾ãããå°ãã ãæãä¸ãã¦è¦ãã¨ãããæ£è¦è¡¨ç¾ã ãã§ã¡ã¼ã«ã¢ãã¬ã¹ããã§ãã¯ãã¦ããå ´åãå£æ» çãªReDoSï¼ååçãæååã§ææ°é¢æ°çã«å®è¡æéãå¢å ããï¼ãå¯è½ãªãã¨ãå¤ãã¾ããã çµè«ãæ¸ãã¨ãæ£è¦è¡¨ç¾ã§ã®ã¡ã¼ã«ã¢ãã¬ã¹ãã§ãã¯ã¯è¦ç´ãã¹ããã§ããï¼ç¹ã«Rubyã¦ã¼ã¶ã¼ï¼ 追è¨ï¼å½±é¿ç¯å²ã¯ã¡ã¼ã«ã¢ãã¬ã¹ãã§ãã¯ã«éããªãã®ã§ãæ£è¦è¡¨ç¾ãã§ãã¯ã¯å ¨ä½çã«è¦ç´ããªãã¨ãã©ããèå¼±ãªã®ãå¤ãã¾ãããè¦ç´ãã¦ãã§ãã¯ããã¨ãã¦ãããããå®å ¨ã§ãã£ãã¨ä¿è¨¼ãããã¨ã¯å°é£ã§ãããããæ¤ç´¢ãã¦ç´ãã«è¦ã¤ãã£ãæ¤ç´¢ãã¿ã¼ã³ã¯é常ã«èå¼±ã§ãã£ããã¨ãã¡ã¼ã«ã¢ãã¬ã¹ã®ããããã¿ã¼ã³ã¯èå¼±ã«ãªããããç¹°ãè¿ãã®ç¹°ãè¿ããå«ã¾ãããã¨ããããããã£ãã®ã§ã¿ã¤ã
ããã㤠æµè¡ãã«ã¯ãã£ããä¹ãããã¦é ãããï¼ line botã¡ããã¡ããéãã§ããä¸ã§åºæ¥ãææç©ãAPIã®rubyè¨èªã©ããã¼ã¨ãã¦gemåãã¨ãã¾ãã^^ Github Rubygems å³ææ§ã並åæ§ãèããã¨ã¬ãBotã«ã¯åãã¦ãªãããã§ããã¾ããµã¯ãã¨éã¶ã¨ãã«ä½¿ã£ã¦ãã ãããª^^ ã¡ãªã¿ã«ãã®ã©ã¤ãã©ãªã¨heroku+Fixieã§ä½ã£ãbotãã²ããããã¨ãããªæã åè: LINE BOT ãã¨ããããã¿ã㧠Heroku ã§åãã æ å ±ã®ãã§ããã ããããªãã¦äºç´ã¨ãä½ãå¯ä½ç¨ã®æã¤ã¢ã¯ã·ã§ã³ã¨çµ¡ããããã°ã«ã¼ããã£ããã«botå ¥ãã¦ã¹ã±ã¼ã¸ã¥ãªã³ã°ã¨ãã¯å¤¢ãåºãããï¼ ä½¿ãæ¹ Installation require 'line/bot/client' client = Line::Bot::Client.new do |config| config.channel
èªååã ã©ãã誰ãè¦ãªãã£ã¦ã show create table è¦ãã»ããæ©ããã mysqldump --no-data -uroot --database employees ããªãã¸ããªã«å ¥ãã¦ãã¼ã¸ã§ã³ç®¡çãã¨ãã°è¯ãã¨æããã©ã ä½ããã®ææ¸åãå¿ è¦ãªå ´åã¯æ¯åå·®åãä¿®æ£ããããå ¨é¨åºåããæ¹ãã©ã¯ã ã«ã©ã åæ¥æ¬èªããããã°é©å½ã« as ã§å¥åã¤ããã¨ããã mysqlã®å ´å #!/bin/bash MYSQL="mysql -B -uroot" DBNAME="employees" TBLSQL=`cat << EOD SELECT TABLE_NAME, TABLE_COMMENT FROM INFORMATION_SCHEMA.TABLES WHERE table_schema = '$DBNAME' AND table_name LIKE '%s' EOD` CO
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}