Fixes variable reference

Fixes variable reference

%root_dir% has been renamed to %release_root_dir%.

:: This batch file handles managing an Erlang node as a Windows service.
::
:: Check the :usage section for information about what this script provides

@echo off

:: Set variables that describe the release
set rel_name=<%= release_name %>
set rel_vsn=<%= release_version %>
set erts_vsn=<%= erts_vsn %>
set erl_opts=<%= erl_opts %>

:: Discover the release root directory from the directory
:: of this script
set script_dir=%~dp0
for %%A in ("%script_dir%\..\..") do (
  set release_root_dir=%%~fA
)
set rel_dir=%release_root_dir%\releases\%rel_vsn%

if "%RELEASE_MUTABLE_DIR%"=="" (
  set mutable_dir=%release_root_dir%\var
) else (
  set mutable_dir=%RELEASE_MUTABLE_DIR%
)

if "%RELEASE_CONFIG_DIR%"=="" (
  set config_dir=%release_root_dir%
) else (
  set config_dir=%RELEASE_CONFIG_DIR%
)

set log_dir=%mutable_dir%\log

:: Create directories which don't exist
if not exist %mutable_dir% mkdir %mutable_dir%
if not exist %config_dir% mkdir %config_dir%
if not exist %log_dir% mkdir %log_dir%

call :find_erts_dir
call :find_sys_config
call :find_vm_args
call :set_boot_script_var

set service_name=%rel_name%_%rel_vsn%
set bindir=%erts_dir%\bin
set progname=erl.exe
set clean_boot_script=%release_root_dir%\bin\start_clean
set erlsrv="%bindir%\erlsrv.exe"
set epmd="%bindir%\epmd.exe"
set escript="%bindir%\escript.exe"
set werl="%bindir%\werl.exe"
set nodetool="%release_root_dir%\bin\nodetool"
set consolidated_dir=%rootdir%\lib\%rel_name%-%rel_vsn%\consolidated
set hook_dir=%rel_dir%\hooks
set command_dir=%rel_dir%\commands

:: Extract node type and name from vm.args
for /f "usebackq tokens=1-2" %%I in (`findstr /b "\-name \-sname" "%vm_args%"`) do (
  set node_type=%%I
  set node_name=%%J
)

:: Extract cookie from vm.args
for /f "usebackq tokens=1-2" %%I in (`findstr /b \-setcookie "%vm_args%"`) do (
  set cookie=%%J
)

:: Write the erl.ini file to set up paths relative to this script
call :write_ini

:: If a start.boot file is not present, copy one from the named .boot file
if not exist "%rel_dir%\start.boot" (
  copy "%rel_dir%\%rel_name%.boot" "%rel_dir%\start.boot" >nul
)

set taskname="%1"
shift /1
set args=

setlocal EnableDelayedExpansion
:parse_args
set param=%1
if "!param!"=="" goto :args_parsed
if "!args!"=="" (
  set largs=%param%
) else (
  set largs=%largs% %param%
)
set "delim= "
shift /1
goto :parse_args
:args_parsed
endlocal & set args=%largs%

if %taskname%=="install" goto install
if %taskname%=="uninstall" goto uninstall
if %taskname%=="start" goto start
if %taskname%=="foreground" goto foreground
if %taskname%=="console" goto console
if %taskname%=="stop" goto stop
if %taskname%=="restart" call :stop && goto start
if %taskname%=="reboot" call :stop && goto start
if %taskname%=="reload_config" goto reload_config
if %taskname%=="upgrade" goto upgrade
if %taskname%=="downgrade" goto upgrade
if %taskname%=="attach" goto remote_console
if %taskname%=="remote_console" goto remote_console
if %taskname%=="pid" goto pid
if %taskname%=="ping" goto ping
if %taskname%=="pingpeer" goto pingpeer
if %taskname%=="escript" goto escript
if %taskname%=="rpc" goto rpc
if %taskname%=="rpcterms" goto rpcterms
if %taskname%=="eval" goto eval
if %taskname%=="command" goto command
if %taskname%=="describe" goto describe
if %taskname%=="" goto usage
if exist "%command_dir%\%taskname%" (
  "%command_dir%\%taskname%" %*
) else (
  echo Unknown command: %taskname%
)
goto :eof

:: Find the ERTS dir
:find_erts_dir
if "%erts_vsn%"=="" (
  call :use_system_erts
) else (
  call :use_bundled_erts
)
goto :eof

:: Load system ERTS info
:use_system_erts
for /f "delims=" %%i in ('where erl') do set system_erl="%%i"
if %system_erl%=="" (
  echo failed to locate the Erlang Runtime System!
  exit 1
)
set system_root_dir_cmd=%system_erl% -noshell -eval "io:format(\"~s\", [filename:nativename(code:root_dir())])." -s init stop
for /f "delims=" %%i in (`%%system_root_dir_cmd%%`) do set system_root=%%i
set system_erts_vsn_cmd=%system_erl% -noshell -eval "Ver=erlang:system_info(version),io:format(\"~s\", [Ver])" -s init stop
for /f "delims=" %%i in (`%%system_erts_vsn_cmd%%`) do set system_erts_vsn=%%i
set erl=%system_erl%
set erts_vsn=%system_erts_vsn%
set rootdir=%system_root%
set erts_dir=%rootdir%\erts-%erts_vsn%
goto :eof

:: Load bundled ERTS info
:use_bundled_erts
set erts_dir=%release_root_dir%\erts-%erts_vsn%
set erl=%erts_dir%\bin\erl
set rootdir=%release_root_dir%
goto :eof

:: Find the sys.config file
:find_sys_config
set possible_sys=%release_config_dir%\sys.config
if exist %possible_sys% (
  set sys_config_src=%possible_sys%
) else (
  set sys_config_src=%rel_dir%\sys.config
)
set sys_config_target=%config_dir%\sys.config
:: Replace environment variables
powershell -command "$content = get-content %sys_config_src%; [regex]::matches($content, '\${[\w\d_-]+}') | foreach { $content = $content.Replace($_.value, [System.Environment]::GetEnvironmentVariable($_.value)) }; out-file -filepath %sys_config_target% -inputobject $content -encoding ascii"
set sys_config=%sys_config_target%
goto :eof

:find_vm_args
set possible_vmargs=%release_config_dir%\vm.args
if exist %possible_vmargs% (
  set vmargs_src=%possible_vmargs%
) else (
  set vmargs_src=%rel_dir%\vm.args
)
set vmargs_target=%config_dir%\vm.args
:: Replace environment variables
powershell -command "$content = get-content %vmargs_src%; [regex]::matches($content, '\${[\w\d_-]+}') | foreach { $content = $content.Replace($_.value, [System.Environment]::GetEnvironmentVariable($_.value)) }; out-file -filepath %vmargs_target% -inputobject $content -encoding ascii"
set vm_args=%vmargs_target%
goto :eof

:: set boot_script variable
:set_boot_script_var
if exist %rel_dir%\%rel_name%.boot (
  set boot_script=%rel_dir%\%rel_name%
) else (
  set boot_script=%rel_dir%\start
)
goto :eof

:: Write the erl.ini file
:write_ini
set erl_ini=%erts_dir%\bin\erl.ini
set converted_bindir=%bindir:\=\\%
set converted_rootdir=%rootdir:\=\\%
echo [erlang] > "%erl_ini%"
echo Bindir=%converted_bindir% >> "%erl_ini%"
echo Progname=%progname% >> "%erl_ini%"
echo Rootdir=%converted_rootdir% >> "%erl_ini%"
goto :eof

:: Display usage information
:usage
echo Usage: %~n0 ^<task^>
echo.
echo Service Control
echo =====================
echo install                             # installs the release as a service
echo uninstall                           # uninstalls the release service
echo start                               # starts the service
echo start_boot                          # not implemented
echo foreground                          # start the release in the foreground
echo console                             # run the release in a local shell
echo console_clean                       # not implemented
echo stop                                # stops the service
echo restart                             # restarts the release service
echo reboot                              # alias for restart on Windows
echo reload_config                       # reload the current system's configuration from disk
echo.
echo Upgrades
echo =====================
echo upgrade ^<version^>                   # upgrade the current release service
echo downgrade ^<version^>                 # downgrade the current release service
echo.
echo Utilities
echo =====================
echo attach                              # alias for remote_console on Windows
echo remote_console                      # open a remote console connected to the release
echo pid                                 # get the process id of the running release
echo ping                                # ping the current release service, pong is returned if ok
echo pingpeer ^<peer^>                     # check if a peer node is running, pong is returned if ok
echo escript ^<file^>                      # execute an escript
echo rpc ^<mod^> ^<fun^> ^[^<args..^>^]          # execute an RPC call using the given MFA
echo rpcterms ^<mod^> ^<fun^> ^[^<expr^>^]       # execute an RPC call using the given Erlang expr for args
echo eval ^<expr^>                         # execute the given Erlang expr on the running node
echo command ^<mod^> ^<fun^> ^[^<args..^>^]      # execute the given module/function in a clean VM
echo describe                            # list details about the release
echo.
echo Custom Commands
echo ======================
for %%i in (%command_dir%\*.d\*.bat) do (
  echo %%~ni
)
goto :eof

:: Install the release as a Windows service
:: or install the specified version passed as argument
:install
setlocal EnableDelayedExpansion
set service_args=%erl_opts% -setcookie "!cookie!" ++ ^
       -rootdir "%rootdir%" ^
       -reldir "%release_root_dir%\releases"
set start_erl=%erts_dir%\bin\start_erl.exe
set description=Erlang node %node_name% in %rootdir%
if "" == "%args%" (
  :: Install the service
  %erlsrv% add %service_name% ^
            -c "%description%" ^
            %node_type% "%node_name%" ^
            -w "%mutable_dir%" ^
            -m "%start_erl%" ^
            -args "!service_args!" ^
            -debugtype new ^
            -stopaction "init:stop()."
  endlocal
) else (
  :: relup and reldown
  endlocal
  goto upgrade
)
goto :eof

:: Uninstall the Windows service
:uninstall
%erlsrv% remove %service_name%
%epmd% -kill
goto :eof

:: Start the Windows service
:start
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
%erlsrv% start %service_name%
call :post_start_hooks
goto :eof

:: Stop the Windows service
:stop
call :pre_stop_hooks
%erlsrv% stop %service_name%
call :post_stop_hooks
goto :eof

:: Upgrade this release
:upgrade
setlocal EnableDelayedExpansion
if "" == "%args%" (
  echo Missing version argument
  echo Usage: %rel_name% %taskname% {version}
  set ERRORLEVEL=1
  exit /b %ERRORLEVEL%
)
set source_version=%rel_vsn%
set target_version=%args%
:: Unpack
%escript% "%release_root_dir%\bin\release_utils.escript" ^
    unpack_release %rel_name% "%node_type%" "%node_name%" "!cookie!" "%target_version%"
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
:: Update env
set rel_vsn=%target_version%
set rel_dir=%release_root_dir\releases\%target_version%
:: TODO: init_configs
if exists "%rel_dir%\sys.config.bak" do (
  move /Y "%rel_dir%\sys.config.bak" "%rel_dir%\sys.config"
)
if exists "%rel_dir%\vm.args.bak" do (
  move /Y "%rel_dir%\vm.args.bak" "%rel_dir%\vm.args"
)
copy /B /Y "%rel_dir%/sys.config" "%rel_dir%\sys.config.bak"
copy /B /Y "%rel_dir%/vm.args" "%rel_dir%\vm.args.bak"
copy /B /Y "%sys_config" "%rel_dir%/sys.config"
copy /B /Y "%vm_args%" "%rel_dir%/vm.args"
:: Run pre hooks
call :pre_configure_hooks
call :post_configure_hooks
call :pre_upgrade_hooks
:: Perform upgrade
%escript% "%rootdir%/bin/release_utils.escript" ^
    install_release "%rel_name%" "%node_type%" "%node_name%" "!cookie!" "%target_version%"
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
:: Cleanup
move /Y "%rel_dir%\sys.config.bak" "%rel_dir%\sys.config"
move /Y "%rel_dir%\vm.args.bak" "%rel_dir%\vm.args"
:: Run post hooks
call :post_upgrade_hooks
endlocal
goto :eof

:: Start a console
:console
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
start "%rel_name% console" %werl% -boot "%boot_script%" ^
       -config "%sys_config%"  ^
       -args_file "%vm_args%" ^
       -user Elixir.IEx.CLI ^
       -extra --no-halt +iex
goto :eof

:: Start the release in the foreground
:foreground
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
set EMU=beam
set PROGNAME=%~n0
start "" /B "%erl%" -noshell -noinput +Bd ^
       -boot "%boot_script%" ^
       -boot_var ERTS_LIB_DIR "%erts_dir%\..\lib" ^
       -env ERL_LIBS "%release_root_dir%\lib%" ^
       -pa "%consolidated_dir%" ^
       -args_file "%vm_args%" ^
       -config "%sys_config%" ^
       %erl_opts% ^
       -extra %extra_opts%
call :set_pid
call :post_start_hooks

:wait_for_exit
tasklist /FI "PID eq %pid%" | find /I "erl.exe"
if %ERRORLEVEL% geq 1 (
  :: Process has shutdown
  call :post_stop_hooks
) else (
  sleep 5
  goto :wait_for_exit
)
goto :eof

:: Ping the running node
:ping
setlocal EnableDelayedExpansion
%escript% %nodetool% ping %node_type% "%node_name%" -setcookie "!cookie!"
endlocal
goto :eof

:: Ping a peer node
:: Ping a peer node
:pingpeer
setlocal EnableDelayedExpansion
if "%args"=="" (
  echo "Peer name is required!"
  exit 1
) else (
  %escript% %nodetool% ping %node_type% "%args%" -setcookie "!cookie!"
)
endlocal
goto :eof

:: Execute an escript
:escript
%escript% %args%
goto :eof

:: Execute an RPC command
:rpc
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% rpc %node_type% %node_name% -setcookie "!cookie!" %args%
endlocal
goto :eof

:: Execute an RPC command where args are expressed
:: in the form of an Erlang expression
:rpcterms
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% rpcterms %node_type% %node_name% -setcookie "!cookie!" %args%
endlocal
goto :eof

:: Eval an expression on the running node
:eval
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" !args!
endlocal
goto :eof

:: Execute a command in a clean Erlang VM
:command
for /f "tokens=1-2*" %%a in ("%args%") do (
  set module=%%a
  set function=%%b
  set command_args=%%c
)
%erl% -boot_var ERTS_LIB_DIR "%erts_dir%\..\lib" ^
       -hidden -noshell -boot start_clean ^
       -pa "%consolidated_dir%" ^
       -s %module% %function% -s init stop
       -extra %command_args%
goto :eof

:: Get the process id of the running node
:pid
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" "erlang:list_to_integer(os:getpid())."
endlocal
goto :eof

:set_pid
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
set get_pid_cmd=%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" "erlang:list_to_integer(os:getpid())."
for /f "usebackq delims=" %%i in (`%%get_pid_cmd%%`) do set pid=%%i
endlocal & set pid=%pid%
goto :eof

:: Reload the running configuration
:reload_config
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
call :pre_configure_hooks
call :post_configure_hooks
setlocal EnableDelayedExpansion
%escript% %nodetool% reload_config %node_type% %node_name% -setcookie "!cookie!" "%sys_config%"
endlocal
goto :eof

:: Describe this release
:describe
setlocal EnableDelayedExpansion
echo Service Information
echo =====================
%erlsrv% list %service_name%
echo.
echo Release Metadata
echo =====================
echo ERTS                %erts_vsn%
echo Release Directory   %rel_dir%
echo Config File         %sys_config%
echo Args File           %vm_args%
echo Name Type           %node_type%
echo Node Name           %node_name%
echo Node Cookie         !cookie!
echo Extra Opts          %erl_opts%
echo.
echo Hooks:
for %%i in (%hook_dir%\*.d\*.bat) do (
  echo %%i
)
echo.
echo Commands:
for %%i in (%command_dir%\*.d\*.bat) do (
  echo %%i
)
endlocal
goto :eof

:: Remote shell to a running node
:remote_console
call :ping
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
set id=remsh%RANDOM%-%node_name%
start "%node_name% attach" %werl% -hidden -noshell -boot "%clean_boot_script%" ^
       -user Elixir.IEx.CLI %node_type% %id% -setcookie "!cookie!" ^
       -extra --no-halt +iex -%node_type% %id% --cookie "!cookie!" --remsh %node_name%
endlocal
goto :eof

:: Hook helpers
:execute_hooks
for /r "%hook_dir%\%1.d" %%f in (*.bat) do (
  echo Running %1 hook: %%f
  %%f
  if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
)
goto :eof

:pre_configure_hooks
call :execute_hooks pre_configure
goto :eof

:post_configure_hooks
call :execute_hooks post_configure
goto :eof

:pre_start_hooks
call :execute_hooks pre_start
goto :eof

:post_start_hooks
call :execute_hooks post_start
goto :eof

:pre_stop_hooks
call :execute_hooks pre_stop
goto :eof

:post_stop_hooks
call :execute_hooks post_stop
goto :eof

:pre_upgrade_hooks
call :execute_hooks pre_upgrade
goto :eof

:post_upgrade_hooks
call :execute_hooks post_upgrade
goto :eof

:: This batch file handles managing an Erlang node as a Windows service.
::
:: Check the :usage section for information about what this script provides

@echo off

:: Set variables that describe the release
set rel_name=<%= release_name %>
set rel_vsn=<%= release_version %>
set erts_vsn=<%= erts_vsn %>
set erl_opts=<%= erl_opts %>

:: Discover the release root directory from the directory
:: of this script
set script_dir=%~dp0
for %%A in ("%script_dir%\..\..") do (
  set release_root_dir=%%~fA
)
set rel_dir=%release_root_dir%\releases\%rel_vsn%

if "%RELEASE_MUTABLE_DIR%"=="" (
  set mutable_dir=%release_root_dir%\var
) else (
  set mutable_dir=%RELEASE_MUTABLE_DIR%
)

if "%RELEASE_CONFIG_DIR%"=="" (
  set config_dir=%release_root_dir%
) else (
  set config_dir=%RELEASE_CONFIG_DIR%
)

set log_dir=%mutable_dir%\log

:: Create directories which don't exist
if not exist %mutable_dir% mkdir %mutable_dir%
if not exist %config_dir% mkdir %config_dir%
if not exist %log_dir% mkdir %log_dir%

call :find_erts_dir
call :find_sys_config
call :find_vm_args
call :set_boot_script_var

set service_name=%rel_name%_%rel_vsn%
set bindir=%erts_dir%\bin
set progname=erl.exe
set clean_boot_script=%release_root_dir%\bin\start_clean
set erlsrv="%bindir%\erlsrv.exe"
set epmd="%bindir%\epmd.exe"
set escript="%bindir%\escript.exe"
set werl="%bindir%\werl.exe"
set nodetool="%release_root_dir%\bin\nodetool"
set consolidated_dir=%rootdir%\lib\%rel_name%-%rel_vsn%\consolidated
set hook_dir=%rel_dir%\hooks
set command_dir=%rel_dir%\commands

:: Extract node type and name from vm.args
for /f "usebackq tokens=1-2" %%I in (`findstr /b "\-name \-sname" "%vm_args%"`) do (
  set node_type=%%I
  set node_name=%%J
)

:: Extract cookie from vm.args
for /f "usebackq tokens=1-2" %%I in (`findstr /b \-setcookie "%vm_args%"`) do (
  set cookie=%%J
)

:: Write the erl.ini file to set up paths relative to this script
call :write_ini

:: If a start.boot file is not present, copy one from the named .boot file
if not exist "%rel_dir%\start.boot" (
  copy "%rel_dir%\%rel_name%.boot" "%rel_dir%\start.boot" >nul
)

set taskname="%1"
shift /1
set args=

setlocal EnableDelayedExpansion
:parse_args
set param=%1
if "!param!"=="" goto :args_parsed
if "!args!"=="" (
  set largs=%param%
) else (
  set largs=%largs% %param%
)
set "delim= "
shift /1
goto :parse_args
:args_parsed
endlocal & set args=%largs%

if %taskname%=="install" goto install
if %taskname%=="uninstall" goto uninstall
if %taskname%=="start" goto start
if %taskname%=="foreground" goto foreground
if %taskname%=="console" goto console
if %taskname%=="stop" goto stop
if %taskname%=="restart" call :stop && goto start
if %taskname%=="reboot" call :stop && goto start
if %taskname%=="reload_config" goto reload_config
if %taskname%=="upgrade" goto upgrade
if %taskname%=="downgrade" goto upgrade
if %taskname%=="attach" goto remote_console
if %taskname%=="remote_console" goto remote_console
if %taskname%=="pid" goto pid
if %taskname%=="ping" goto ping
if %taskname%=="pingpeer" goto pingpeer
if %taskname%=="escript" goto escript
if %taskname%=="rpc" goto rpc
if %taskname%=="rpcterms" goto rpcterms
if %taskname%=="eval" goto eval
if %taskname%=="command" goto command
if %taskname%=="describe" goto describe
if %taskname%=="" goto usage
if exist "%command_dir%\%taskname%" (
  "%command_dir%\%taskname%" %*
) else (
  echo Unknown command: %taskname%
)
goto :eof

:: Find the ERTS dir
:find_erts_dir
if "%erts_vsn%"=="" (
  call :use_system_erts
) else (
  call :use_bundled_erts
)
goto :eof

:: Load system ERTS info
:use_system_erts
for /f "delims=" %%i in ('where erl') do set system_erl="%%i"
if %system_erl%=="" (
  echo failed to locate the Erlang Runtime System!
  exit 1
)
set system_root_dir_cmd=%system_erl% -noshell -eval "io:format(\"~s\", [filename:nativename(code:root_dir())])." -s init stop
for /f "delims=" %%i in (`%%system_root_dir_cmd%%`) do set system_root=%%i
set system_erts_vsn_cmd=%system_erl% -noshell -eval "Ver=erlang:system_info(version),io:format(\"~s\", [Ver])" -s init stop
for /f "delims=" %%i in (`%%system_erts_vsn_cmd%%`) do set system_erts_vsn=%%i
set erl=%system_erl%
set erts_vsn=%system_erts_vsn%
set rootdir=%system_root%
set erts_dir=%rootdir%\erts-%erts_vsn%
goto :eof

:: Load bundled ERTS info
:use_bundled_erts
set erts_dir=%release_root_dir%\erts-%erts_vsn%
set erl=%erts_dir%\bin\erl
set rootdir=%release_root_dir%
goto :eof

:: Find the sys.config file
:find_sys_config
set possible_sys=%release_config_dir%\sys.config
if exist %possible_sys% (
  set sys_config_src=%possible_sys%
) else (
  set sys_config_src=%rel_dir%\sys.config
)
set sys_config_target=%config_dir%\sys.config
:: Replace environment variables
powershell -command "$content = get-content %sys_config_src%; [regex]::matches($content, '\${[\w\d_-]+}') | foreach { $content = $content.Replace($_.value, [System.Environment]::GetEnvironmentVariable($_.value)) }; out-file -filepath %sys_config_target% -inputobject $content -encoding ascii"
set sys_config=%sys_config_target%
goto :eof

:find_vm_args
set possible_vmargs=%release_config_dir%\vm.args
if exist %possible_vmargs% (
  set vmargs_src=%possible_vmargs%
) else (
  set vmargs_src=%rel_dir%\vm.args
)
set vmargs_target=%config_dir%\vm.args
:: Replace environment variables
powershell -command "$content = get-content %vmargs_src%; [regex]::matches($content, '\${[\w\d_-]+}') | foreach { $content = $content.Replace($_.value, [System.Environment]::GetEnvironmentVariable($_.value)) }; out-file -filepath %vmargs_target% -inputobject $content -encoding ascii"
set vm_args=%vmargs_target%
goto :eof

:: set boot_script variable
:set_boot_script_var
if exist %rel_dir%\%rel_name%.boot (
  set boot_script=%rel_dir%\%rel_name%
) else (
  set boot_script=%rel_dir%\start
)
goto :eof

:: Write the erl.ini file
:write_ini
set erl_ini=%erts_dir%\bin\erl.ini
set converted_bindir=%bindir:\=\\%
set converted_rootdir=%rootdir:\=\\%
echo [erlang] > "%erl_ini%"
echo Bindir=%converted_bindir% >> "%erl_ini%"
echo Progname=%progname% >> "%erl_ini%"
echo Rootdir=%converted_rootdir% >> "%erl_ini%"
goto :eof

:: Display usage information
:usage
echo Usage: %~n0 ^<task^>
echo.
echo Service Control
echo =====================
echo install                             # installs the release as a service
echo uninstall                           # uninstalls the release service
echo start                               # starts the service
echo start_boot                          # not implemented
echo foreground                          # start the release in the foreground
echo console                             # run the release in a local shell
echo console_clean                       # not implemented
echo stop                                # stops the service
echo restart                             # restarts the release service
echo reboot                              # alias for restart on Windows
echo reload_config                       # reload the current system's configuration from disk
echo.
echo Upgrades
echo =====================
echo upgrade ^<version^>                   # upgrade the current release service
echo downgrade ^<version^>                 # downgrade the current release service
echo.
echo Utilities
echo =====================
echo attach                              # alias for remote_console on Windows
echo remote_console                      # open a remote console connected to the release
echo pid                                 # get the process id of the running release
echo ping                                # ping the current release service, pong is returned if ok
echo pingpeer ^<peer^>                     # check if a peer node is running, pong is returned if ok
echo escript ^<file^>                      # execute an escript
echo rpc ^<mod^> ^<fun^> ^[^<args..^>^]          # execute an RPC call using the given MFA
echo rpcterms ^<mod^> ^<fun^> ^[^<expr^>^]       # execute an RPC call using the given Erlang expr for args
echo eval ^<expr^>                         # execute the given Erlang expr on the running node
echo command ^<mod^> ^<fun^> ^[^<args..^>^]      # execute the given module/function in a clean VM
echo describe                            # list details about the release
echo.
echo Custom Commands
echo ======================
for %%i in (%command_dir%\*.d\*.bat) do (
  echo %%~ni
)
goto :eof

:: Install the release as a Windows service
:: or install the specified version passed as argument
:install
setlocal EnableDelayedExpansion
set service_args=%erl_opts% -setcookie "!cookie!" ++ ^
       -rootdir "%rootdir%" ^
       -reldir "%release_root_dir%\releases"
set start_erl=%erts_dir%\bin\start_erl.exe
set description=Erlang node %node_name% in %rootdir%
if "" == "%args%" (
  :: Install the service
  %erlsrv% add %service_name% ^
            -c "%description%" ^
            %node_type% "%node_name%" ^
            -w "%mutable_dir%" ^
            -m "%start_erl%" ^
            -args "!service_args!" ^
            -debugtype new ^
            -stopaction "init:stop()."
  endlocal
) else (
  :: relup and reldown
  endlocal
  goto upgrade
)
goto :eof

:: Uninstall the Windows service
:uninstall
%erlsrv% remove %service_name%
%epmd% -kill
goto :eof

:: Start the Windows service
:start
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
%erlsrv% start %service_name%
call :post_start_hooks
goto :eof

:: Stop the Windows service
:stop
call :pre_stop_hooks
%erlsrv% stop %service_name%
call :post_stop_hooks
goto :eof

:: Upgrade this release
:upgrade
setlocal EnableDelayedExpansion
if "" == "%args%" (
  echo Missing version argument
  echo Usage: %rel_name% %taskname% {version}
  set ERRORLEVEL=1
  exit /b %ERRORLEVEL%
)
set source_version=%rel_vsn%
set target_version=%args%
:: Unpack
%escript% "%root_dir%\bin\release_utils.escript" ^
    unpack_release %rel_name% "%node_type%" "%node_name%" "!cookie!" "%target_version%"
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
:: Update env
set rel_vsn=%target_version%
set rel_dir=%release_root_dir\releases\%target_version%
:: TODO: init_configs
if exists "%rel_dir%\sys.config.bak" do (
  move /Y "%rel_dir%\sys.config.bak" "%rel_dir%\sys.config"
)
if exists "%rel_dir%\vm.args.bak" do (
  move /Y "%rel_dir%\vm.args.bak" "%rel_dir%\vm.args"
)
copy /B /Y "%rel_dir%/sys.config" "%rel_dir%\sys.config.bak"
copy /B /Y "%rel_dir%/vm.args" "%rel_dir%\vm.args.bak"
copy /B /Y "%sys_config" "%rel_dir%/sys.config"
copy /B /Y "%vm_args%" "%rel_dir%/vm.args"
:: Run pre hooks
call :pre_configure_hooks
call :post_configure_hooks
call :pre_upgrade_hooks
:: Perform upgrade
%escript% "%rootdir%/bin/release_utils.escript" ^
    install_release "%rel_name%" "%node_type%" "%node_name%" "!cookie!" "%target_version%"
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
:: Cleanup
move /Y "%rel_dir%\sys.config.bak" "%rel_dir%\sys.config"
move /Y "%rel_dir%\vm.args.bak" "%rel_dir%\vm.args"
:: Run post hooks
call :post_upgrade_hooks
endlocal
goto :eof

:: Start a console
:console
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
start "%rel_name% console" %werl% -boot "%boot_script%" ^
       -config "%sys_config%"  ^
       -args_file "%vm_args%" ^
       -user Elixir.IEx.CLI ^
       -extra --no-halt +iex
goto :eof

:: Start the release in the foreground
:foreground
call :pre_configure_hooks
call :post_configure_hooks
call :pre_start_hooks
set EMU=beam
set PROGNAME=%~n0
start "" /B "%erl%" -noshell -noinput +Bd ^
       -boot "%boot_script%" ^
       -boot_var ERTS_LIB_DIR "%erts_dir%\..\lib" ^
       -env ERL_LIBS "%release_root_dir%\lib%" ^
       -pa "%consolidated_dir%" ^
       -args_file "%vm_args%" ^
       -config "%sys_config%" ^
       %erl_opts% ^
       -extra %extra_opts%
call :set_pid
call :post_start_hooks

:wait_for_exit
tasklist /FI "PID eq %pid%" | find /I "erl.exe"
if %ERRORLEVEL% geq 1 (
  :: Process has shutdown
  call :post_stop_hooks
) else (
  sleep 5
  goto :wait_for_exit
)
goto :eof

:: Ping the running node
:ping
setlocal EnableDelayedExpansion
%escript% %nodetool% ping %node_type% "%node_name%" -setcookie "!cookie!"
endlocal
goto :eof

:: Ping a peer node
:: Ping a peer node
:pingpeer
setlocal EnableDelayedExpansion
if "%args"=="" (
  echo "Peer name is required!"
  exit 1
) else (
  %escript% %nodetool% ping %node_type% "%args%" -setcookie "!cookie!"
)
endlocal
goto :eof

:: Execute an escript
:escript
%escript% %args%
goto :eof

:: Execute an RPC command
:rpc
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% rpc %node_type% %node_name% -setcookie "!cookie!" %args%
endlocal
goto :eof

:: Execute an RPC command where args are expressed
:: in the form of an Erlang expression
:rpcterms
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% rpcterms %node_type% %node_name% -setcookie "!cookie!" %args%
endlocal
goto :eof

:: Eval an expression on the running node
:eval
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" !args!
endlocal
goto :eof

:: Execute a command in a clean Erlang VM
:command
for /f "tokens=1-2*" %%a in ("%args%") do (
  set module=%%a
  set function=%%b
  set command_args=%%c
)
%erl% -boot_var ERTS_LIB_DIR "%erts_dir%\..\lib" ^
       -hidden -noshell -boot start_clean ^
       -pa "%consolidated_dir%" ^
       -s %module% %function% -s init stop
       -extra %command_args%
goto :eof

:: Get the process id of the running node
:pid
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" "erlang:list_to_integer(os:getpid())."
endlocal
goto :eof

:set_pid
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
set get_pid_cmd=%escript% %nodetool% eval %node_type% %node_name% -setcookie "!cookie!" "erlang:list_to_integer(os:getpid())."
for /f "usebackq delims=" %%i in (`%%get_pid_cmd%%`) do set pid=%%i
endlocal & set pid=%pid%
goto :eof

:: Reload the running configuration
:reload_config
call :ping>NUL
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
call :pre_configure_hooks
call :post_configure_hooks
setlocal EnableDelayedExpansion
%escript% %nodetool% reload_config %node_type% %node_name% -setcookie "!cookie!" "%sys_config%"
endlocal
goto :eof

:: Describe this release
:describe
setlocal EnableDelayedExpansion
echo Service Information
echo =====================
%erlsrv% list %service_name%
echo.
echo Release Metadata
echo =====================
echo ERTS                %erts_vsn%
echo Release Directory   %rel_dir%
echo Config File         %sys_config%
echo Args File           %vm_args%
echo Name Type           %node_type%
echo Node Name           %node_name%
echo Node Cookie         !cookie!
echo Extra Opts          %erl_opts%
echo.
echo Hooks:
for %%i in (%hook_dir%\*.d\*.bat) do (
  echo %%i
)
echo.
echo Commands:
for %%i in (%command_dir%\*.d\*.bat) do (
  echo %%i
)
endlocal
goto :eof

:: Remote shell to a running node
:remote_console
call :ping
if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
setlocal EnableDelayedExpansion
set id=remsh%RANDOM%-%node_name%
start "%node_name% attach" %werl% -hidden -noshell -boot "%clean_boot_script%" ^
       -user Elixir.IEx.CLI %node_type% %id% -setcookie "!cookie!" ^
       -extra --no-halt +iex -%node_type% %id% --cookie "!cookie!" --remsh %node_name%
endlocal
goto :eof

:: Hook helpers
:execute_hooks
for /r "%hook_dir%\%1.d" %%f in (*.bat) do (
  echo Running %1 hook: %%f
  %%f
  if %ERRORLEVEL% GEQ 1 exit %ERRORLEVEL%
)
goto :eof

:pre_configure_hooks
call :execute_hooks pre_configure
goto :eof

:post_configure_hooks
call :execute_hooks post_configure
goto :eof

:pre_start_hooks
call :execute_hooks pre_start
goto :eof

:post_start_hooks
call :execute_hooks post_start
goto :eof

:pre_stop_hooks
call :execute_hooks pre_stop
goto :eof

:post_stop_hooks
call :execute_hooks post_stop
goto :eof

:pre_upgrade_hooks
call :execute_hooks pre_upgrade
goto :eof

:post_upgrade_hooks
call :execute_hooks post_upgrade
goto :eof


we can do it simpler

we can do it simpler

Top 5 liked Podcasts

    <%= for {[count, id, title], rank} <- Enum.with_index(@liked_podcasts) do %>

        <%= if rank == 0 || count != List.first(Enum.at(@liked_podcasts, rank-1)) do %>
          <%= rank + 1 %>.:
        <% else %>

        <% end %>
        <%= link [fa_icon("podcast"), " ", truncate(title, 50)],
                 to: podcast_frontend_path(@conn, :show, id),
                 class: "btn btn-default btn-xs",
                 style: "color: #000" %>
        <%= count %> <%= fa_icon("user") %>

    <% end %>

Top 5 liked Podcasts

    <%= for {[count, id, title], rank} <- Enum.with_index(@liked_podcasts) do %>

        <%= if rank == 0 || count != @liked_podcasts[rank-1][0] do %>
          <%= rank + 1 %>.:
        <% else %>

        <% end %>
        <%= link [fa_icon("podcast"), " ", truncate(title, 50)],
                 to: podcast_frontend_path(@conn, :show, id),
                 class: "btn btn-default btn-xs",
                 style: "color: #000" %>
        <%= count %> <%= fa_icon("user") %>

    <% end %>


fix: delete is now a button

fix: delete is now a button

Listing mentions

  <%= for mention <- @mentions do %>

Typ

<%= mention.mention_type %>

Source

<%= link mention.source_url, to: mention.source_url %>

Target

<%= link mention.target_url, to: mention.target_url %>

Title

<%= mention.title %>

Excerpt

<%= mention.excerpt %>

Author

          <%= if mention.author_url do %><%= link mention.author, to: mention.author_url %>
          <% else %><%= mention.author %><% end %>

        <%= if String.strip(to_string(mention.author_avatar)) != "" do %>

Avatar

<img alt="" class="avatar" src="<%= cache_path(@conn, :show, url: mention.author_avatar) %>">

            <%= mention.author_avatar %>

        <% end %>

Created

<%= Wwwtech.Mention.inserted_at_timex(mention) |> DateFormat.format!("%Y-%m-%d %H:%M", :strftime) %>

<%= Wwwtech.Mention.updated_at_timex(mention) |> DateFormat.format!("%Y-%m-%d %H:%M", :strftime) %>

        <%= link "Edit", to: mention_path(@conn, :edit, mention) %> /
        <%= button "Delete", to: mention_path(@conn, :delete, mention), method: :delete, data: [confirm: "Are you sure?"] %>

  <% end %>

Listing mentions

  <%= for mention <- @mentions do %>

Typ

<%= mention.mention_type %>

Source

<%= link mention.source_url, to: mention.source_url %>

Target

<%= link mention.target_url, to: mention.target_url %>

Title

<%= mention.title %>

Excerpt

<%= mention.excerpt %>

Author

          <%= if mention.author_url do %><%= link mention.author, to: mention.author_url %>
          <% else %><%= mention.author %><% end %>

        <%= if String.strip(to_string(mention.author_avatar)) != "" do %>

Avatar

<img alt="" class="avatar" src="<%= cache_path(@conn, :show, url: mention.author_avatar) %>">

            <%= mention.author_avatar %>

        <% end %>

Created

<%= Wwwtech.Mention.inserted_at_timex(mention) |> DateFormat.format!("%Y-%m-%d %H:%M", :strftime) %>

<%= Wwwtech.Mention.updated_at_timex(mention) |> DateFormat.format!("%Y-%m-%d %H:%M", :strftime) %>

        <%= link "Edit", to: mention_path(@conn, :edit, mention) %> /
        <%= link "Delete", to: mention_path(@conn, :delete, mention), method: :delete, data: [confirm: "Are you sure?"] %>

  <% end %>


Clean posting/index template

Clean posting/index template

<%= if @referred_via_elixirweekly do %>

        <img src="<%= static_path(@conn, "/images/elixirweekly-thumb.png") %>"/>

    Welcome!
    Submit your posts for the next ElixirWeekly!

<% end %>

  <%= if logged_in?(@conn) do %>
    <%= if @page_number == 1 do %>
      <%= if @just_signed_in do %>

          <%= render "form.html", current_user: current_user(@conn),
                                  changeset: @changeset,
                                  action: posting_path(@conn, :create),
                                  conn: @conn,
                                  posting: nil,
                                  css_class: "post--new",
                                  editing?: false %>

      <% else %>

            <div class="image" style="background-image: url(<%= raw avatar_path(current_user(@conn).user_name) %>)">

           Submit a post

          <%= render "form.html", current_user: current_user(@conn),
                                  changeset: @changeset,
                                  action: posting_path(@conn, :create),
                                  conn: @conn,
                                  posting: nil,
                                  css_class: "post--new",
                                  editing?: false %>

      <% end %>
    <% else %>

          <div class="image" style="background-image: url(<%= raw avatar_path(current_user(@conn).user_name) %>)">

         Submit another post

    <% end %>
  <% else %>

       Sign in and post

  <% end %>

  <%= if @searching? do %>
    Search results for <%= @search_query %>
    clear
  <% end %>

  <% #= render ElixirStatus.PostingView, "_tab_nav_index.html", assigns %>

  <%= for {posting, index} <- Enum.with_index(@postings) do %>
    <%= render ElixirStatus.PostingView, "posting.html", conn: @conn,
                posting: posting,
                belongs_to_me?: ElixirStatus.Auth.belongs_to_current_user?(@conn, posting),
                just_created_by_me?: @created_posting == posting
                %>
    <%= if index == 2 || index == 8 do %>
      <%= render ElixirStatus.SharedView, "promo_elixirweekly.html", conn: @conn %>
    <% end %>
  <% end %>

  <%= if @page_number > 1 do %>
    <%= link "Previous", to: posting_path(@conn, :index, page: @page_number - 1), class: "pagination__item pagination__item--older" %>
  <% else %>
    Previous
  <% end %>
  <%= if @page_number < @total_pages do %>
    <%= link "Next", to: posting_path(@conn, :index, page: @page_number + 1), class: "pagination__item pagination__item--newer" %>
  <% else %>
    Next
  <% end %>

  <form method="get" action="/">
    <input type="text" name="q" class="search__input" placeholder="Search ...">
  </form>

<%= if @referred_via_elixirweekly do %>

        <img src="<%= static_path(@conn, "/images/elixirweekly-thumb.png") %>"/>

    Welcome!
    Submit your posts for the next ElixirWeekly!

<% end %>

  <%= if logged_in?(@conn) do %>
    <%= if @page_number == 1 do %>
      <%= if @just_signed_in do %>

          <%= render "form.html", current_user: current_user(@conn),
                                  changeset: @changeset,
                                  action: posting_path(@conn, :create),
                                  conn: @conn,
                                  posting: nil,
                                  css_class: "post--new",
                                  editing?: false %>

      <% else %>

            <div class="image" style="background-image: url(<%= raw avatar_path(current_user(@conn).user_name) %>)">

           Submit a post

          <%= render "form.html", current_user: current_user(@conn),
                                  changeset: @changeset,
                                  action: posting_path(@conn, :create),
                                  conn: @conn,
                                  posting: nil,
                                  css_class: "post--new",
                                  editing?: false %>

      <% end %>
    <% else %>

          <div class="image" style="background-image: url(<%= raw avatar_path(current_user(@conn).user_name) %>)">

         Submit another post

    <% end %>
  <% else %>

       Sign in and post

  <% end %>

  <%= if @searching? do %>
    Search results for <%= @search_query %>
    clear
  <% end %>

  <% #= render ElixirStatus.PostingView, "_tab_nav_index.html", assigns %>

Today

  <%= for {posting, index} <- Enum.with_index(@postings) do %>
    <%= render ElixirStatus.PostingView, "posting.html", conn: @conn,
                posting: posting,
                belongs_to_me?: ElixirStatus.Auth.belongs_to_current_user?(@conn, posting),
                just_created_by_me?: @created_posting == posting
                %>
    <%= if index == 2 || index == 8 do %>
      <%= render ElixirStatus.SharedView, "promo_elixirweekly.html", conn: @conn %>
    <% end %>
  <% end %>

  <%= if @page_number > 1 do %>
    <%= link "Previous", to: posting_path(@conn, :index, page: @page_number - 1), class: "pagination__item pagination__item--older" %>
  <% else %>
    Previous
  <% end %>
  <%= if @page_number < @total_pages do %>
    <%= link "Next", to: posting_path(@conn, :index, page: @page_number + 1), class: "pagination__item pagination__item--newer" %>
  <% else %>
    Next
  <% end %>

  <form method="get" action="/">
    <input type="text" name="q" class="search__input" placeholder="Search ...">
  </form>


Check for loaded channel association

Check for loaded channel association

<!DOCTYPE html>

    <title>
      <%= page_title(assigns) %> - Today I Learned
    </title>

    <meta name="csrf" content="<%= Plug.CSRFProtection.get_csrf_token() %>">

    <meta name="format-detection" content="telephone=no">
    <meta name="description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day.">

    <meta itemprop="name" content="Today I Learned">
    <meta itemprop="brand" content="Today I Learned">
    <meta itemprop="description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day.">

    <meta name="viewport" content="width=device-width, initial-scale=1">

    <meta name="twitter:card" content="summary_large_image">
    <meta name="twitter:site" content="@hashrockettil">
    <meta name="twitter:creator" content="@hashrockettil">
    <meta name="twitter:title" content="Today I Learned: a Hashrocket Project">

    <%= if assigns[:post] do %>
      <meta name="twitter:description" content="<%= Tilex.Post.twitter_description(assigns[:post]) %>">
    <% else %>
      <meta name="twitter:description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day. Posts have a 200-word limit, and posting is open to any Rocketeer as well as select friends of the team. We hope you enjoy learning along with us.">
    <% end %>

    <%= if assigns[:post] && Ecto.assoc_loaded?(assigns[:post].channel) && File.exists?("assets/static/assets/#{String.replace(assigns[:post].channel.name, "-", "_")}_twitter_card.png") do %>
      <meta name="twitter:image" content=<%= TilexWeb.Endpoint.static_url() <> "/assets/#{String.replace(assigns[:post].channel.name, "-", "_")}_twitter_card.png}" %>>
    <% else %>
      <meta name="twitter:image" content=<%= TilexWeb.Endpoint.static_url() <> "/assets/til_twittercard.png" %>>
    <% end %>

    <link href='//fonts.googleapis.com/css?family=Raleway:700,900' rel='stylesheet' type='text/css'>
    <link href='//fonts.googleapis.com/css?family=Lora:400,700italic,700,400italic' rel='stylesheet' type='text/css'>
    <link rel="alternate feed" type="application/rss+xml" title="Today I Learned" href="/rss">

    <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css">

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
    <%= if assigns[:canonical_url] do %>
      <link rel="canonical" href="<%= @canonical_url %>">
    <% end %>
    <link rel="manifest" href="<%= web_manifest_path(@conn, :index) %>">

    <%= if developer = Guardian.Plug.current_resource(@conn) do %>

 <%= link(developer.username, to: developer_path(@conn, :show, developer)) %>

 <%= link("Sign Out", to: auth_path(@conn, :delete), method: :delete) %>

 <%= link("Create Post", to: post_path(@conn, :new)) %>

 <%= link("Profile", to: developer_path(@conn, :edit)) %>

    <% end %>

Today I Learned

          A Hashrocket project

            Follow on Twitter

      <%= if message = get_flash(@conn, :info) do %>

          <%= message %>

      <% end %>

      <%= render @view_module, @view_template, assigns %>

          <%= link("search", to: "#", class: "site_nav__link") %>

            <%= form_tag post_path(@conn, :index), method: :get do %>
              <input type="search" name="q" id="q">
              <%= submit "Search" %>
            <% end %>

          <%= link("?", to: "#", class: "site_nav__link") %>

              Today I Learned is an open-source project by

                Hashrocket

              that exists to catalogue the sharing & accumulation of knowledge
              as it happens day-to-day. Posts have a 200-word limit, and
              posting is open to any Rocketeer as well as selected friends of
              Hashrocket. We hope you enjoy learning along with us.

                  <%= link("/hashrockettil", to: "https://twitter.com/hashrockettil", class: "social_twitter") %>

                  <%= link("/hashrocket/tilex", to: "https://github.com/hashrocket/tilex", class: "social_github") %>

          <%= link("Statistics", to: "/statistics", class: "site_nav__link") %>

            <%= link("Twitter", to: "https://twitter.com/hashrockettil", class: "site_nav__link") %>

            <%= link("Surprise Me", to: "/random", class: "site_nav__link", rel: "nofollow") %>

    <%= if Mix.env != :test do %>

    <% end %>

    <%= if Application.get_env(:tilex, :ga_identifier) do %>

    <% end %>

<!DOCTYPE html>

    <title>
      <%= page_title(assigns) %> - Today I Learned
    </title>

    <meta name="csrf" content="<%= Plug.CSRFProtection.get_csrf_token() %>">

    <meta name="format-detection" content="telephone=no">
    <meta name="description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day.">

    <meta itemprop="name" content="Today I Learned">
    <meta itemprop="brand" content="Today I Learned">
    <meta itemprop="description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day.">

    <meta name="viewport" content="width=device-width, initial-scale=1">

    <meta name="twitter:card" content="summary_large_image">
    <meta name="twitter:site" content="@hashrockettil">
    <meta name="twitter:creator" content="@hashrockettil">
    <meta name="twitter:title" content="Today I Learned: a Hashrocket Project">

    <%= if assigns[:post] do %>
      <meta name="twitter:description" content="<%= Tilex.Post.twitter_description(assigns[:post]) %>">
    <% else %>
      <meta name="twitter:description" content="TIL is an open-source project by Hashrocket that exists to catalogue the sharing & accumulation of knowledge as it happens day-to-day. Posts have a 200-word limit, and posting is open to any Rocketeer as well as select friends of the team. We hope you enjoy learning along with us.">
    <% end %>

    <%= if assigns[:post] && File.exists?("assets/static/assets/#{String.replace(assigns[:post].channel.name, "-", "_")}_twitter_card.png") do %>
      <meta name="twitter:image" content=<%= TilexWeb.Endpoint.static_url() <> "/assets/#{String.replace(assigns[:post].channel.name, "-", "_")}_twitter_card.png}" %>>
    <% else %>
      <meta name="twitter:image" content=<%= TilexWeb.Endpoint.static_url() <> "/assets/til_twittercard.png" %>>
    <% end %>

    <link href='//fonts.googleapis.com/css?family=Raleway:700,900' rel='stylesheet' type='text/css'>
    <link href='//fonts.googleapis.com/css?family=Lora:400,700italic,700,400italic' rel='stylesheet' type='text/css'>
    <link rel="alternate feed" type="application/rss+xml" title="Today I Learned" href="/rss">

    <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/atom-one-dark.min.css">

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">

    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
    <%= if assigns[:canonical_url] do %>
      <link rel="canonical" href="<%= @canonical_url %>">
    <% end %>
    <link rel="manifest" href="<%= web_manifest_path(@conn, :index) %>">

    <%= if developer = Guardian.Plug.current_resource(@conn) do %>

 <%= link(developer.username, to: developer_path(@conn, :show, developer)) %>

 <%= link("Sign Out", to: auth_path(@conn, :delete), method: :delete) %>

 <%= link("Create Post", to: post_path(@conn, :new)) %>

 <%= link("Profile", to: developer_path(@conn, :edit)) %>

    <% end %>

Today I Learned

          A Hashrocket project

            Follow on Twitter

      <%= if message = get_flash(@conn, :info) do %>

          <%= message %>

      <% end %>

      <%= render @view_module, @view_template, assigns %>

          <%= link("search", to: "#", class: "site_nav__link") %>

            <%= form_tag post_path(@conn, :index), method: :get do %>
              <input type="search" name="q" id="q">
              <%= submit "Search" %>
            <% end %>

          <%= link("?", to: "#", class: "site_nav__link") %>

              Today I Learned is an open-source project by

                Hashrocket

              that exists to catalogue the sharing & accumulation of knowledge
              as it happens day-to-day. Posts have a 200-word limit, and
              posting is open to any Rocketeer as well as selected friends of
              Hashrocket. We hope you enjoy learning along with us.

                  <%= link("/hashrockettil", to: "https://twitter.com/hashrockettil", class: "social_twitter") %>

                  <%= link("/hashrocket/tilex", to: "https://github.com/hashrocket/tilex", class: "social_github") %>

          <%= link("Statistics", to: "/statistics", class: "site_nav__link") %>

            <%= link("Twitter", to: "https://twitter.com/hashrockettil", class: "site_nav__link") %>

            <%= link("Surprise Me", to: "/random", class: "site_nav__link", rel: "nofollow") %>

    <%= if Mix.env != :test do %>

    <% end %>

    <%= if Application.get_env(:tilex, :ga_identifier) do %>

    <% end %>


wrap contents of create.html for grants in a container

Congrats!

Expect a copy of your grant proposal coming from eef-grant-submissions@beam.eco


Add login/register

Add login/register

      <img src="<%= static_path(@conn, "/images/logo.png") %>" class="logo"/>

ElixirJobs

<%= gettext "Find your next Elixir job the right way." %>

    <input type="checkbox" class="sidebar-checkbox" id="sidebar-checkbox">

      <%= gettext "Publish a job offer" %>
      Login
      Register

      <%= gettext "You can follow via" %>
      Twitter
      RSS

      <%= gettext "Running on Phoenix!" %>
      <%= gettext "Open Source" %>
      <%= gettext "About" %>

      <img src="<%= static_path(@conn, "/images/logo.png") %>" class="logo"/>

ElixirJobs

<%= gettext "Find your next Elixir job the right way." %>

<%= gettext "Publsh your job offers where they matter." %>

    <input type="checkbox" class="sidebar-checkbox" id="sidebar-checkbox">

      <%= gettext "Publish a job offer" %>

      <%= gettext "You can follow via" %>
      Twitter
      RSS

      <%= gettext "Running on Phoenix!" %>
      <%= gettext "Open Source" %>
      <%= gettext "About" %>


feat(admin): better edit form

feat(admin): better edit form

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

  <%= for {id, column} <- @columns do %>
    <%= unless id == :id do %>

        <%= label f, id, class: "control-label" %>
        <%= case column.type do
              :boolean -> checkbox f, id, class: "form-control"
              :integer -> number_input f, id, class: "form-control"
              :datetime -> datetime_select f, id, class: "form-control"
              _ -> text_input f, id, class: "form-control"
            end
        %>
        <%= error_tag f, id %>

    <% end %>
  <% end %>

    <%= submit "Submit", class: "btn btn-primary" %>

<% end %>

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

  <%= for {id, column} <- @columns do %>
    <%= unless id == :id do %>

        <%= label f, id, class: "control-label" %>
        <%= text_input f, id, class: "form-control" %>
        <%= error_tag f, id %>

    <% end %>
  <% end %>

    <%= submit "Submit", class: "btn btn-primary" %>

<% end %>


Add render info

Add render info

<script src="//cdn.jsdelivr.net/phaser-ce/2.7.3/phaser.min.js"></script>

<script type="text/javascript">

window.onload = function() {

    var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create, update: update, render: render });

    function preload () {

        game.load.image('logo', 'images/phoenix.png');

    }

    var logo
    var cursors

    function create () {

        logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
        logo.anchor.setTo(0.5, 0.5);

        cursors = game.input.keyboard.createCursorKeys();
    }

    function update () {
        if (cursors.left.isDown) {
            logo.x -= 4;
        }
        else if (cursors.right.isDown) {
            logo.x += 4;
        }

        if (cursors.up.isDown){
            logo.y -= 4;
        } else if (cursors.down.isDown) {
           logo.y += 4;
        }
    }

    function render () {

      game.debug.spriteInfo(logo, 32, 32);

    }

};

</script>

<script src="//cdn.jsdelivr.net/phaser-ce/2.7.3/phaser.min.js"></script>

<script type="text/javascript">

window.onload = function() {

    var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create, update: update });

    function preload () {

        game.load.image('logo', 'images/phoenix.png');

    }

    var logo
    var cursors

    function create () {

        logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
        logo.anchor.setTo(0.5, 0.5);

        cursors = game.input.keyboard.createCursorKeys();
    }

    function update () {
        if (cursors.left.isDown) {
            logo.x -= 4;
        }
        else if (cursors.right.isDown) {
            logo.x += 4;
        }

        if (cursors.up.isDown){
            logo.y -= 4;
        } else if (cursors.down.isDown) {
           logo.y += 4;
        }

    }

    function render () {

    }

};

</script>


Adding better description to the tooltip

<%= @title %> ( <%=total @stat %>
    <%= if @type == "current_month" do %>
        <i title="Last month you had <%= total @previous %> hours." class="<%= trend(@stat, @previous) %>">
    <% end %>

    <%= if @type == "current_year" do %>
        <i title="By this month last year you had <%= total @previous %> hours." class="<%= trend(@stat, @previous) %>">
    <% end %>
)

    <%= for s <- @stat do %>

<%= s.name %>

<%= s.sum %>

    <% end %>

<div class="charts" id="<%= @type %>">

<%= @title %> ( <%=total @stat %>
<i title="How you're doing compared to the previous time period." class="<%= trend(@stat, @previous) %>">)

    <%= for s <- @stat do %>

<%= s.name %>

<%= s.sum %>

    <% end %>

<div class="charts" id="<%= @type %>">


ref: load JS asynchronously

ref: load JS asynchronously

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>

    <link rel="alternate" type="application/atom+xml" title="WWWTech / What's new? (Combined feed)" href="<%= Routes.page_url(@conn, :index_atom) %>">
    <link rel="alternate" type="application/atom+xml" title="WWWTech / Articles" href="<%= Routes.article_url(@conn, :index) %>.atom">
    <link rel="alternate" type="application/atom+xml" title="WWWTech / Notes" href="<%= Routes.note_url(@conn, :index) %>.atom">
    <link rel="alternate" type="application/atom+xml" title="WWWTech / Pictures" href="<%= Routes.picture_url(@conn, :index) %>.atom">

    <link rel="pgpkey" type="application/pgp-keys" href="/A99A9D73.asc">

    <link rel="apple-touch-icon" href="<%= Routes.static_path(@conn, "/images/christian-kruse.jpg") %>">
    <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">

    <link rel="author" href="<%= Routes.page_path(@conn, :index) %>humans.txt" type="text/plain">

    <link rel="webmention" href="<%= Routes.webmention_url(@conn, :create) %>">

    <meta name="description" content="<%= description(@conn, assigns) %>">
    <meta name="author" content="Christian Kruse">

    <title><%= page_title(@conn, assigns) %></title>

    <meta property="og:title" content="<%= page_title(@conn, assigns) %>">
    <meta property="og:type" content="website">
    <meta property="og:image" content="<%= Routes.static_path(@conn, "/images/christian-kruse.jpg") %>">

    <link rel="stylesheet" href="<%= Routes.static_path(@conn, "/css/app.css") %>"/>

<%= link "WWWTech", to: Routes.page_url(@conn, :index) %>

Open Source Software and Publications by <%= link "Christian Kruse", to: Routes.page_path(@conn, :about) %>

<%= link "Home", to: Routes.page_path(@conn, :index) %>

<%= link "About Me", to: Routes.page_path(@conn, :about) %>

<%= link "Software", to: Routes.page_path(@conn, :software) %>

<%= link "Articles", to: Routes.article_path(@conn, :index) %>

<%= link "Notes", to: Routes.note_path(@conn, :index) %>

<%= link "Pictures", to: Routes.picture_path(@conn, :index) %>

<%= link "More", to: Routes.page_path(@conn, :more) %>

        <%= if logged_in?(@conn) do %>

<%= button "Logout", to: Routes.session_path(@conn, :delete), method: :delete %>

        <% end %>

      <%= if info = get_flash(@conn, :info) do %>
<%= info %>
<% end %>
      <%= if error = get_flash(@conn, :error) do %>
<%= error %><% end %>

      <%= render @view_module, @view_template, assigns %>

<%= link "Legal Notice", to: Routes.page_path(@conn, :about), rel: "me" %>

<%= link "cjk@defunct.ch", to: "mailto:cjk@defunct.ch", rel: "me" %> via Email


add waves effect to team submit button

add waves effect to team submit button

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

  <%= if @team == %TicketPoker.Team{} do %>
    <%= render "welcome.html" %>
  <% else %>

Team URL (bookmark this to return)

          <%= team_url(@conn, :show, @team) %>
          assignment

  <% end %>

      <%= label f, :team_name %>
      <%= text_input f, :name, class: "form-control" %>
      <%= error_tag f, :name %>

      <%= label f, :ticket_sizes %>
      <%= text_input f, :points_string, class: "form-control" %>
      The set of possible ticket sizes used by your team
      <%= error_tag f, :points %>

      <%= label f, :members %>
      <textarea class="materialize-textarea" id="team_coders" name="team[coders]"><%= coders_string(@team.coders) %></textarea>
      List the members of your team who will supply estimates for tickets, one name per line
      <%= error_tag f, :coders %>

      <%= label f, :new_ticket %>
      <%= text_input f, :new_ticket_url, class: "form-control" %>
      Enter the title of a ticket to estimate, or paste its URL from your planning system (e.g. Trello/Pivotal)
      <%= error_tag f, :new_ticket_url %>

      <%= submit "Submit", class: "btn btn-primary waves-effect" %>

<% end %>

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

  <%= if @team == %TicketPoker.Team{} do %>
    <%= render "welcome.html" %>
  <% else %>

Team URL (bookmark this to return)

          <%= team_url(@conn, :show, @team) %>
          assignment

  <% end %>

      <%= label f, :team_name %>
      <%= text_input f, :name, class: "form-control" %>
      <%= error_tag f, :name %>

      <%= label f, :ticket_sizes %>
      <%= text_input f, :points_string, class: "form-control" %>
      The set of possible ticket sizes used by your team
      <%= error_tag f, :points %>

      <%= label f, :members %>
      <textarea class="materialize-textarea" id="team_coders" name="team[coders]"><%= coders_string(@team.coders) %></textarea>
      List the members of your team who will supply estimates for tickets, one name per line
      <%= error_tag f, :coders %>

      <%= label f, :new_ticket %>
      <%= text_input f, :new_ticket_url, class: "form-control" %>
      Enter the title of a ticket to estimate, or paste its URL from your planning system (e.g. Trello/Pivotal)
      <%= error_tag f, :new_ticket_url %>

      <%= submit "Submit", class: "btn btn-primary" %>

<% end %>


Adding title

Adding title

<!doctype html>

    <title>rockerBOO / Dave Lage</title>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <link rel="stylesheet" href="<%= static_path(@conn, "/css/vendor.css") %>">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

rockerBOO

About Me

Projects

Contact Me

    <%= @inner %>

<!doctype html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">

    <link rel="stylesheet" href="<%= static_path(@conn, "/css/vendor.css") %>">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

rockerBOO

About Me

Projects

Contact Me

        <%= @inner %>


cyr font

cyr font

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Uber History</title>
    <link href="https://fonts.googleapis.com/css?family=Roboto:100,300,400&subset=cyrillic,cyrillic-ext" rel="stylesheet">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/application.css") %>">

<%= get_flash(@conn, :info) %>

<%= get_flash(@conn, :error) %>

    <%= render @view_module, @view_template, assigns %>

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <title>Uber History</title>
    <link href="https://fonts.googleapis.com/css?family=Roboto:100,300,400" rel="stylesheet">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/application.css") %>">

<%= get_flash(@conn, :info) %>

<%= get_flash(@conn, :error) %>

    <%= render @view_module, @view_template, assigns %>


Looks like Phoenix already comes with bootstrap

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Hello Phoenix!</title>
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

Get Started

<%= get_flash(@conn, :info) %>

<%= get_flash(@conn, :error) %>

      <%= @inner %>

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Hello Phoenix!</title>

    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">

    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

Get Started

<%= get_flash(@conn, :info) %>

<%= get_flash(@conn, :error) %>

      <%= @inner %>


Move code around

Move code around

<script src="//cdn.jsdelivr.net/phaser-ce/2.7.3/phaser.min.js"></script>

<script type="text/javascript">

window.onload = function() {

    var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create, update: update, render: render });

    var logo
    var cursors

    function preload () {

        game.load.image('logo', 'images/phoenix.png');

    }

    function create () {

        logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
        logo.anchor.setTo(0.5, 0.5);

        cursors = game.input.keyboard.createCursorKeys();
    }

    function update () {
        if (cursors.left.isDown) {
            logo.x -= 4;
        }
        else if (cursors.right.isDown) {
            logo.x += 4;
        }

        if (cursors.up.isDown) {
            logo.y -= 4;
        }
        else if (cursors.down.isDown) {
           logo.y += 4;
        }
    }

    function render () {

      game.debug.spriteInfo(logo, 32, 32);

    }

};

</script>

<script src="//cdn.jsdelivr.net/phaser-ce/2.7.3/phaser.min.js"></script>

<script type="text/javascript">

window.onload = function() {

    var game = new Phaser.Game(800, 600, Phaser.AUTO, '', { preload: preload, create: create, update: update, render: render });

    function preload () {

        game.load.image('logo', 'images/phoenix.png');

    }

    var logo
    var cursors

    function create () {

        logo = game.add.sprite(game.world.centerX, game.world.centerY, 'logo');
        logo.anchor.setTo(0.5, 0.5);

        cursors = game.input.keyboard.createCursorKeys();
    }

    function update () {
        if (cursors.left.isDown) {
            logo.x -= 4;
        }
        else if (cursors.right.isDown) {
            logo.x += 4;
        }

        if (cursors.up.isDown){
            logo.y -= 4;
        } else if (cursors.down.isDown) {
           logo.y += 4;
        }
    }

    function render () {

      game.debug.spriteInfo(logo, 32, 32);

    }

};

</script>


mark knocked out contestants

mark knocked out contestants

Who's got whom?

Contestant	Who	Which week were they knocked out?

    <%= for contestant <- @contestants do %>
      <%= if contestant.out do %>

      <% else %>

      <% end %>
        <%= contestant.name %>
        <%= if contestant.user do %>
        <%= contestant.user.name %>
        <% end %>
        <%= contestant.knockedout %>

    <% end %>

Who's got whom?

Contestant	Who

    <%= for contestant <- @contestants do %>

        <%= contestant.name %>
        <%= if contestant.user do %>
        <%= contestant.user.name %>
        <% end %>

    <% end %>


update page template

update page template

Welcome to Personal Twitter Bot

A productive web framework that
does not compromise speed and maintainability.

Resources

        Guides

        Docs

        Source

Help

        Mailing list

        #elixir-lang on freenode IRC

        @elixirphoenix

Welcome to Phoenix!

A productive web framework that
does not compromise speed and maintainability.

Resources

        Guides

        Docs

        Source

Help

        Mailing list

        #elixir-lang on freenode IRC

        @elixirphoenix


Updated homepage, styles

Updated homepage, styles

Cast your vote now!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

    Start voting

Leading Presidentiables

Leading Vice-Presidentiables

Leading Senators

Cast your vote now!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

We are in an information age where we should no longer be poisoned by the media!

    Start voting

Leading Presidentiables

Leading Presidentiables

Leading Presidentiables


adding placeholder votes badge

adding placeholder votes badge

  <%= link "Add new post", to: post_path(@conn, :new), class: "list-group-item active" %>
  <%= for post <- @posts do %>
    <a href="<%= post_path(@conn, :show, post) %>" class="list-group-item">
      0
      <%= post.title %>

  <% end %>

  <%= link "Add new post", to: post_path(@conn, :new), class: "list-group-item active" %>
  <%= for post <- @posts do %>
    <%= link post.title, to: post_path(@conn, :show, post), class: "list-group-item" %>
  <% end %>


Change partitions table icon

Change partitions table icon

Local Partitions (0)

                Index

Local Partitions (0)

                Index


remove flashes

remove flashes

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Hello LearnPhoenix!</title>
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

Get Started

        <%= render @view_module, @view_template, assigns %>

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Hello LearnPhoenix!</title>
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

Get Started

<%= get_flash(@conn, :info) %>

<%= get_flash(@conn, :error) %>

        <%= render @view_module, @view_template, assigns %>


Removed the ad for now.

Removed the ad for now.

  <%= gettext("Ad") %>

AMOOMA GmbH

Phoenix Framework, Ruby on Rails und WebPerformance Consulting und Training durch das vutuv Entwicklerteam.

  https://www.amooma.de


FIx a bit.

FIx a bit.

実験プログラムをダウンロードしています。

このまましばらくお待ちください。

<%= if @host do %>

実験記号: <%= @x_token %>

      実験記号を表示

<% end %>

<%= if @host do %>

実験記号: <%= @x_token %>

      実験記号を表示

<% end %>

実験プログラムをダウンロードしています。

このまましばらくお待ちください。


Change header order

Change header order

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">
    <meta name="apple-mobile-web-app-title" content="ElixirJobs">
    <meta name="application-name" content="ElixirJobs">
    <meta name="theme-color" content="#8652ad">
    <title>ElixirJobs</title>
    <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
    <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
    <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
    <link rel="manifest" href="/manifest.json">
    <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#8652ad">
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

    <%= render_shared "_sidebar.html", conn: @conn %>

        <%= render @view_module, @view_template, assigns %>

    <%= render_shared "_footer.html", conn: @conn %>

<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
    <link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
    <link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
    <link rel="manifest" href="/manifest.json">
    <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#8652ad">
    <meta name="apple-mobile-web-app-title" content="ElixirJobs">
    <meta name="application-name" content="ElixirJobs">
    <meta name="theme-color" content="#8652ad">
    <title>ElixirJobs</title>
    <link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">

    <%= render_shared "_sidebar.html", conn: @conn %>

        <%= render @view_module, @view_template, assigns %>

    <%= render_shared "_footer.html", conn: @conn %>


center player

center player

  <%= case @player do %>
    <%= "podlove" -> %>
      <%= render "_podlove_webplayer4.html", episode: @episode,
                                             conn: @conn %>
    <% "podigee" -> %>

  <% end %>

  <%#
    CDN - Repo: https://cdn.podigee.com/podcast-player/javascripts/podigee-podcast-player.js
    Github - Version: https://podigee.github.io/podigee-podcast-player/build/javascripts/podigee-podcast-player.js
  %>


nav fixes

nav fixes

<!DOCTYPE html>

	<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
	<meta content="width=device-width, initial-scale=1" name="viewport">
	<meta content="BeyondBOINC displays the recently created content from a curated list of Steemit authors on the topics of cryptocurrency, distributed computing and technology." name="description">
	<meta content="Gridcoin, Bitshares, Steemit, Cryptocurrency, Blog, Aggregator, Glasnost, BOINC, BeyondBitcoin, BeyondBOINC, Distributed Computing, Cloud computing, Science, Peerplays, Blockchain, Decentralization, money, science, technology, crypto" name="keywords">
	<meta content="Customminer aka @cm-steem" name="author">
	<meta content="index, follow" name="robots">
	<meta content="1 days" name="revisit-after">

	<link rel="apple-touch-icon" sizes="57x57" href="/images/apple-icon-57x57.png">
	<link rel="apple-touch-icon" sizes="60x60" href="/images/apple-icon-60x60.png">
	<link rel="apple-touch-icon" sizes="72x72" href="/images/apple-icon-72x72.png">
	<link rel="apple-touch-icon" sizes="76x76" href="/images/apple-icon-76x76.png">
	<link rel="apple-touch-icon" sizes="114x114" href="/images/apple-icon-114x114.png">
	<link rel="apple-touch-icon" sizes="120x120" href="/images/apple-icon-120x120.png">
	<link rel="apple-touch-icon" sizes="144x144" href="/images/apple-icon-144x144.png">
	<link rel="apple-touch-icon" sizes="152x152" href="/images/apple-icon-152x152.png">
	<link rel="apple-touch-icon" sizes="180x180" href="/images/apple-icon-180x180.png">
	<link rel="icon" type="image/png" sizes="192x192"  href="/images/android-icon-192x192.png">
	<link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32.png">
	<link rel="icon" type="image/png" sizes="96x96" href="/images/favicon-96x96.png">
	<link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16.png">
	<link rel="manifest" href="/images/manifest.json">
	<meta name="msapplication-TileColor" content="#ffffff">
	<meta name="msapplication-TileImage" content="/images/ms-icon-144x144.png">
	<meta name="theme-color" content="#ffffff">

	<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">

	<link href="https://beyondboinc.net" rel="canonical">
	<title>BeyondBOINC: <%= naive_translate("head title", @conn.assigns[:lang])%></title>
 	<link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
 	<link href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.10/semantic.css" rel="stylesheet">

          			<img class="logo" src="/images/<%=naive_image_chooser("logo", @conn.assigns[:lang])%>">
          			BeyondBOINC

	        	<a href="/authors/<%=@conn.assigns[:about_blog_author]%>/<%=@conn.assigns[:about_blog_permlink]%>" class="item"><%=naive_translate("about", @conn.assigns[:lang])%>

					Trade GRC

							 Decentralized Exchanges

									BitSquare

									OpenLedger

									BTSABC

									BTSBOTS

									Bitshares-Light

							 Centralized Exchanges

									HolyTransactions

									Poloniex

									C-Cex

									Bittrex

							 Explorers

									GridcoinStats

									GridResearchCorp

									Explorer.Gridcoin.Asia

									HolyTransactions

							 Exchange Stats

									CoinMarketCap

									CoinGecko

									CoinCap

					BOINC links

							 Official

									BOINC Website

									BOINC Forums

									GitHub

							 Services

									FormulaBOINC

									User of the day

									Desktop Grid Federation

									Boincstats

									Statsbzh

									DC-Vault

									Free-DC

							 Team Forums

									Rechenkraft

									SETI Germany

									SETI USA

									Free-DC

									Czech national team

									L'Alliance Francophone

									Overclock.Net

									Planet3DNow

					BOINC Projects

							 Official

ATLAS@Home

Cosmology@Home

LHC@Home

theSkyNet POGS

Universe@home

Asteroids@home

Einstein@home

Milkyway@home

SETI@home

							 Multiple Applications

Citizen Science Grid

SZTAKI Desktop Grid

World Community Grid

yoyo@home

							 Mathematics and Computing

Enigma@Home

NFS@Home

NumberFields@home

SRBase

VGTU

YAFU

Amicable Numbers

Collatz Conjecture

Moo! Wrapper

PrimeGrid

							 Earth Sciences

Leiden Classical

							 Biology and Medicine

Rosetta@Home

GPUgrid

					Community links

							 Gridcoin

									Official Website

									Forums

									GitHub

									Twitter

									Steemit

									Telegram

									Reddit

									IRC

									GRC MediaWiki

									GRC @ Wikipedia

							 Bitshares

									Official website

									Forums

									Telegram

									Explorer

							 Peerplays

									Official website

									Telegram

									Peerplays.chat

									GitHub

							 Steemit

									Official website

									Telegram

									Steemit.Chat

									GitHub

									Applications

									Explorer

				  <input placeholder="Search..." type="text" id="Search">
				  <button class="ui icon button" id="Button">

				  </button>

				<%= if get_flash(@conn, :info) do %>

					<%= get_flash(@conn, :info) %>

<%end %><%= if get_flash(@conn, :error) do %>

					<%= get_flash(@conn, :error) %>

<%end %>

<%= render @view_module, @view_template, assigns %>

Promoted Tags

	            Gridcoin
	            BOINC
	            Bitshares
	            BeyondBitcoin
	            Cryptocurrency

Promoted Authors

	            @CM-Steem
	            @OfficialFuzzy
	            @Erkan
	            @SC-Steemit
	            @moisesmcardona

Affiliate links

	            Vultr
	            Namecheap
	            NordVPN
	            Purse.IO
	            CoinPayments

About

BeyondBOINC is a Steemit backed blog, powered by the  Glasnost  library & is actively maintained by @CM-STEEM.

Want to be a featured author? Join the BeyondBOINC Telegram Chat to apply.

GRC Address: SCyjzkycFPZ1pgR2WP4xvk9o5AD5kArWfX

	      <img class="ui centered mini image" src="/images/<%=naive_image_chooser("logo", @conn.assigns[:lang])%>">

	        Home
	        Site Map
	        BeyondBOINC Telegram Chat

<!DOCTYPE html>

	<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
	<meta content="width=device-width, initial-scale=1" name="viewport">
	<meta content="BeyondBOINC displays the recently created content from a curated list of Steemit authors on the topics of cryptocurrency, distributed computing and technology." name="description">
	<meta content="Gridcoin, Bitshares, Steemit, Cryptocurrency, Blog, Aggregator, Glasnost, BOINC, BeyondBitcoin, BeyondBOINC, Distributed Computing, Cloud computing, Science, Peerplays, Blockchain, Decentralization, money, science, technology, crypto" name="keywords">
	<meta content="Customminer aka @cm-steem" name="author">
	<meta content="index, follow" name="robots">
	<meta content="1 days" name="revisit-after">

	<link rel="apple-touch-icon" sizes="57x57" href="/images/apple-icon-57x57.png">
	<link rel="apple-touch-icon" sizes="60x60" href="/images/apple-icon-60x60.png">
	<link rel="apple-touch-icon" sizes="72x72" href="/images/apple-icon-72x72.png">
	<link rel="apple-touch-icon" sizes="76x76" href="/images/apple-icon-76x76.png">
	<link rel="apple-touch-icon" sizes="114x114" href="/images/apple-icon-114x114.png">
	<link rel="apple-touch-icon" sizes="120x120" href="/images/apple-icon-120x120.png">
	<link rel="apple-touch-icon" sizes="144x144" href="/images/apple-icon-144x144.png">
	<link rel="apple-touch-icon" sizes="152x152" href="/images/apple-icon-152x152.png">
	<link rel="apple-touch-icon" sizes="180x180" href="/images/apple-icon-180x180.png">
	<link rel="icon" type="image/png" sizes="192x192"  href="/images/android-icon-192x192.png">
	<link rel="icon" type="image/png" sizes="32x32" href="/images/favicon-32x32.png">
	<link rel="icon" type="image/png" sizes="96x96" href="/images/favicon-96x96.png">
	<link rel="icon" type="image/png" sizes="16x16" href="/images/favicon-16x16.png">
	<link rel="manifest" href="/images/manifest.json">
	<meta name="msapplication-TileColor" content="#ffffff">
	<meta name="msapplication-TileImage" content="/images/ms-icon-144x144.png">
	<meta name="theme-color" content="#ffffff">

	<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">

	<link href="https://beyondboinc.net" rel="canonical">
	<title>BeyondBOINC: <%= naive_translate("head title", @conn.assigns[:lang])%></title>
 	<link rel="stylesheet" href="<%= static_path(@conn, "/css/app.css") %>">
 	<link href="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui/2.2.10/semantic.css" rel="stylesheet">

          			<img class="logo" src="/images/<%=naive_image_chooser("logo", @conn.assigns[:lang])%>">
          			BeyondBOINC

	        	<a href="/authors/<%=@conn.assigns[:about_blog_author]%>/<%=@conn.assigns[:about_blog_permlink]%>" class="item"><%=naive_translate("about", @conn.assigns[:lang])%>

					Trade GRC

							 Decentralized Exchanges

									BitSquare

									OpenLedger

									BTSABC

									BTSBOTS

									Bitshares-Light

							 Centralized Exchanges

									HolyTransactions

									Poloniex

									C-Cex

									Bittrex

							 Explorers

									GridcoinStats

									GridResearchCorp

									Explorer.Gridcoin.Asia

									HolyTransactions

							 Exchange Stats

									CoinMarketCap

									CoinGecko

									CoinCap

					BOINC links

							 Official

									BOINC Website

									BOINC Forums

									GitHub

							 Services

									FormulaBOINC

									User of the day

									Desktop Grid Federation

									Boincstats

									Statsbzh

									DC-Vault

									Free-DC

							 Team Forums

									Rechenkraft

									SETI Germany

									SETI USA

									Free-DC

									Czech national team

									L'Alliance Francophone

									Overclock.Net

									Planet3DNow

							 Projects

									 Physical Science

ATLAS@Home

Cosmology@Home

LHC@Home

theSkyNet POGS

Universe@home

Asteroids@home

Einstein@home

Milkyway@home

SETI@home

									 Multiple Applications

Citizen Science Grid

SZTAKI Desktop Grid

World Community Grid

yoyo@home

									 Mathematics and Computing

Enigma@Home

NFS@Home

NumberFields@home

SRBase

VGTU

YAFU

Amicable Numbers

Collatz Conjecture

Moo! Wrapper

PrimeGrid

									 Earth Sciences

Leiden Classical

									 Biology and Medicine

Rosetta@Home

GPUgrid

					Community links

							 Gridcoin

									Official Website

									Forums

									GitHub

									Twitter

									Steemit

									Telegram

									Reddit

									IRC

									GRC MediaWiki

									GRC @ Wikipedia

							 Bitshares

									Official website

									Forums

									Telegram

									Explorer

							 Peerplays

									Official website

									Telegram

									Peerplays.chat

									GitHub

							 Steemit

									Official website

									Telegram

									Steemit.Chat

									GitHub

									Applications

									Explorer

				  <input placeholder="Search..." type="text" id="Search">
				  <button class="ui icon button" id="Button">

				  </button>

				<%= if get_flash(@conn, :info) do %>

					<%= get_flash(@conn, :info) %>

<%end %><%= if get_flash(@conn, :error) do %>

					<%= get_flash(@conn, :error) %>

<%end %>

<%= render @view_module, @view_template, assigns %>

Promoted Tags

	            Gridcoin
	            BOINC
	            Bitshares
	            BeyondBitcoin
	            Cryptocurrency

Promoted Authors

	            @CM-Steem
	            @OfficialFuzzy
	            @Erkan
	            @SC-Steemit
	            @moisesmcardona

Affiliate links

	            Vultr
	            Namecheap
	            NordVPN
	            Purse.IO
	            CoinPayments

About

BeyondBOINC is a Steemit backed blog, powered by the  Glasnost  library & is actively maintained by @CM-STEEM.

Want to be a featured author? Join the BeyondBOINC Telegram Chat to apply.

GRC Address: SCyjzkycFPZ1pgR2WP4xvk9o5AD5kArWfX

	      <img class="ui centered mini image" src="/images/<%=naive_image_chooser("logo", @conn.assigns[:lang])%>">

	        Home
	        Site Map
	        BeyondBOINC Telegram Chat


Show badges below title line

Show badges below title line

  <%= if file_url(@asciicast) do %>
    <%= player @asciicast, @playback_options %>
  <% else %>

          This movie was recorded with quite old version of asciinema and needs
          extra pre-processing. Just a few more seconds!

          Feel free to contact admin@asciinema.org if it takes more than a minute.

  <% end %>

          <%= link to: author_profile_path(@asciicast), title: author_username(@asciicast) do %>
            <%= img_tag author_avatar_url(@asciicast), class: "avatar" %>
          <% end %>

          <%= title(@asciicast) %>

          by <%= link author_username(@asciicast), to: author_profile_path(@asciicast) %>
          <%= time_ago_tag @asciicast.created_at %>

          <%= if @asciicast.private do %>
            <%= render "_private_badge.html" %>
          <% end %>

          <%= if @asciicast.featured do %>
            <%= render "_featured_badge.html" %>
          <% end %>

          <%= link "Share", to: "#", class: "btn btn-sm btn-secondary", id: "share-link", "data-toggle": "modal", "data-target": "#share-modal" %>

          <%= if download_filename(@asciicast) do %>
            <%= link "Download", to: "#", class: "btn btn-sm btn-secondary", id: "download-link", "data-toggle": "modal", "data-target": "#download-modal" %>
          <% end %>

          <%= if length(@actions) > 0 do %>
            <button class="btn btn-sm btn-secondary dropdown-toggle" type="button" data-toggle="dropdown">
              Settings
            </button>

              <%= if :edit in @actions do %>
                <%= link "Edit", to: asciicast_path(@conn, :edit, @asciicast), class: "dropdown-item" %>
              <% end %>

              <%= if :make_featured in @actions do %>
                <%= link "Make featured", to: asciicast_path(@conn, :update, @asciicast, asciicast: [featured: 1]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_not_featured in @actions do %>
                <%= link "Make not featured", to: asciicast_path(@conn, :update, @asciicast, asciicast: [featured: 0]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_private in @actions do %>
                <%= link "Make private", to: asciicast_path(@conn, :update, @asciicast, asciicast: [private: 1]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_public in @actions do %>
                <%= link "Make public", to: asciicast_path(@conn, :update, @asciicast, asciicast: [private: 0]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :delete in @actions do %>
                <%= link "Delete", to: asciicast_path(@conn, :delete, @asciicast), class: "dropdown-item text-danger", method: :delete, data: [confirm: "Are you sure you want to delete this?"] %>
              <% end %>

          <% end %>

        <img src="data:image/svg+xml;utf8;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTYuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjUxMnB4IiBoZWlnaHQ9IjUxMnB4IiB2aWV3Qm94PSIwIDAgNDUuOTk5IDQ1Ljk5OSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgNDUuOTk5IDQ1Ljk5OTsiIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8Zz4KCTxnPgoJCTxwYXRoIGQ9Ik0zOS4yNjQsNi43MzZjLTguOTgyLTguOTgxLTIzLjU0NS04Ljk4Mi0zMi41MjgsMGMtOC45ODIsOC45ODItOC45ODEsMjMuNTQ1LDAsMzIuNTI4YzguOTgyLDguOTgsMjMuNTQ1LDguOTgxLDMyLjUyOCwwICAgIEM0OC4yNDUsMzAuMjgxLDQ4LjI0NCwxNS43MTksMzkuMjY0LDYuNzM2eiBNMjUuOTk5LDMzYzAsMS42NTctMS4zNDMsMy0zLDNzLTMtMS4zNDMtMy0zVjIxYzAtMS42NTcsMS4zNDMtMywzLTNzMywxLjM0MywzLDNWMzN6ICAgICBNMjIuOTQ2LDE1Ljg3MmMtMS43MjgsMC0yLjg4LTEuMjI0LTIuODQ0LTIuNzM1Yy0wLjAzNi0xLjU4NCwxLjExNi0yLjc3MSwyLjg3OS0yLjc3MWMxLjc2NCwwLDIuODgsMS4xODgsMi45MTcsMi43NzEgICAgQzI1Ljg5NywxNC42NDgsMjQuNzQ2LDE1Ljg3MiwyMi45NDYsMTUuODcyeiIgZmlsbD0iIzZjNzU3ZCIvPgoJPC9nPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+Cjwvc3ZnPgo=" />

        <%= if os = os_info(@asciicast) do %>
          OS=<%= os %>
        <% end %>

        <%= if shell = shell_info(@asciicast) do %>
          SHELL=<%= shell %>
        <% end %>

        <%= if term = term_info(@asciicast) do %>
          TERM=<%= term %>
        <% end %>

        VIEWS=<%= views_count(@asciicast) %>

        <%= if desc = description(@asciicast) do %>

            <%= desc %>

        <% end %>

<%= case @author_asciicasts do %>
  <% [] -> %>
  <% asciicasts -> %>

More by <%= link author_username(@asciicast), to: author_profile_path(@asciicast) %>

                <%= for asciicast <- asciicasts do %>

                    <%= render AsciinemaWeb.AsciicastView, "_card.html", conn: @conn, asciicast: asciicast %>

                <% end %>

              <%= link "See all", to: author_profile_path(@asciicast), class: "btn btn-info" %>

<% end %>

<%= render "_share_modal.html", conn: @conn, asciicast: @asciicast %>

<%= if download_filename(@asciicast) do %>
  <%= render "_download_modal.html", conn: @conn, asciicast: @asciicast %>
<% end %>

  <%= if file_url(@asciicast) do %>
    <%= player @asciicast, @playback_options %>
  <% else %>

          This movie was recorded with quite old version of asciinema and needs
          extra pre-processing. Just a few more seconds!

          Feel free to contact admin@asciinema.org if it takes more than a minute.

  <% end %>

          <%= link to: author_profile_path(@asciicast), title: author_username(@asciicast) do %>
            <%= img_tag author_avatar_url(@asciicast), class: "avatar" %>
          <% end %>

          <%= title(@asciicast) %>

          <%= if @asciicast.private do %>
            <%= render "_private_badge.html" %>
          <% end %>

          <%= if @asciicast.featured do %>
            <%= render "_featured_badge.html" %>
          <% end %>

        by <%= link author_username(@asciicast), to: author_profile_path(@asciicast) %> <%= if !assigns[:no_created_at] do %><%= time_ago_tag @asciicast.created_at %><% end %>

          <%= link "Share", to: "#", class: "btn btn-sm btn-secondary", id: "share-link", "data-toggle": "modal", "data-target": "#share-modal" %>

          <%= if download_filename(@asciicast) do %>
            <%= link "Download", to: "#", class: "btn btn-sm btn-secondary", id: "download-link", "data-toggle": "modal", "data-target": "#download-modal" %>
          <% end %>

          <%= if length(@actions) > 0 do %>
            <button class="btn btn-sm btn-secondary dropdown-toggle" type="button" data-toggle="dropdown">
              Settings
            </button>

              <%= if :edit in @actions do %>
                <%= link "Edit", to: asciicast_path(@conn, :edit, @asciicast), class: "dropdown-item" %>
              <% end %>

              <%= if :make_featured in @actions do %>
                <%= link "Make featured", to: asciicast_path(@conn, :update, @asciicast, asciicast: [featured: 1]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_not_featured in @actions do %>
                <%= link "Make not featured", to: asciicast_path(@conn, :update, @asciicast, asciicast: [featured: 0]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_private in @actions do %>
                <%= link "Make private", to: asciicast_path(@conn, :update, @asciicast, asciicast: [private: 1]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :make_public in @actions do %>
                <%= link "Make public", to: asciicast_path(@conn, :update, @asciicast, asciicast: [private: 0]), class: "dropdown-item", method: :put %>
              <% end %>

              <%= if :delete in @actions do %>
                <%= link "Delete", to: asciicast_path(@conn, :delete, @asciicast), class: "dropdown-item text-danger", method: :delete, data: [confirm: "Are you sure you want to delete this?"] %>
              <% end %>

          <% end %>

        <img src="data:image/svg+xml;utf8;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iaXNvLTg4NTktMSI/Pgo8IS0tIEdlbmVyYXRvcjogQWRvYmUgSWxsdXN0cmF0b3IgMTYuMC4wLCBTVkcgRXhwb3J0IFBsdWctSW4gLiBTVkcgVmVyc2lvbjogNi4wMCBCdWlsZCAwKSAgLS0+CjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+CjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgdmVyc2lvbj0iMS4xIiBpZD0iQ2FwYV8xIiB4PSIwcHgiIHk9IjBweCIgd2lkdGg9IjUxMnB4IiBoZWlnaHQ9IjUxMnB4IiB2aWV3Qm94PSIwIDAgNDUuOTk5IDQ1Ljk5OSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgNDUuOTk5IDQ1Ljk5OTsiIHhtbDpzcGFjZT0icHJlc2VydmUiPgo8Zz4KCTxnPgoJCTxwYXRoIGQ9Ik0zOS4yNjQsNi43MzZjLTguOTgyLTguOTgxLTIzLjU0NS04Ljk4Mi0zMi41MjgsMGMtOC45ODIsOC45ODItOC45ODEsMjMuNTQ1LDAsMzIuNTI4YzguOTgyLDguOTgsMjMuNTQ1LDguOTgxLDMyLjUyOCwwICAgIEM0OC4yNDUsMzAuMjgxLDQ4LjI0NCwxNS43MTksMzkuMjY0LDYuNzM2eiBNMjUuOTk5LDMzYzAsMS42NTctMS4zNDMsMy0zLDNzLTMtMS4zNDMtMy0zVjIxYzAtMS42NTcsMS4zNDMtMywzLTNzMywxLjM0MywzLDNWMzN6ICAgICBNMjIuOTQ2LDE1Ljg3MmMtMS43MjgsMC0yLjg4LTEuMjI0LTIuODQ0LTIuNzM1Yy0wLjAzNi0xLjU4NCwxLjExNi0yLjc3MSwyLjg3OS0yLjc3MWMxLjc2NCwwLDIuODgsMS4xODgsMi45MTcsMi43NzEgICAgQzI1Ljg5NywxNC42NDgsMjQuNzQ2LDE1Ljg3MiwyMi45NDYsMTUuODcyeiIgZmlsbD0iIzZjNzU3ZCIvPgoJPC9nPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+CjxnPgo8L2c+Cjwvc3ZnPgo=" />

        <%= if os = os_info(@asciicast) do %>
          OS=<%= os %>
        <% end %>

        <%= if shell = shell_info(@asciicast) do %>
          SHELL=<%= shell %>
        <% end %>

        <%= if term = term_info(@asciicast) do %>
          TERM=<%= term %>
        <% end %>

        VIEWS=<%= views_count(@asciicast) %>

        <%= if desc = description(@asciicast) do %>

            <%= desc %>

        <% end %>

<%= case @author_asciicasts do %>
  <% [] -> %>
  <% asciicasts -> %>

More by <%= link author_username(@asciicast), to: author_profile_path(@asciicast) %>

                <%= for asciicast <- asciicasts do %>

                    <%= render AsciinemaWeb.AsciicastView, "_card.html", conn: @conn, asciicast: asciicast %>

                <% end %>

              <%= link "See all", to: author_profile_path(@asciicast), class: "btn btn-info" %>

<% end %>

<%= render "_share_modal.html", conn: @conn, asciicast: @asciicast %>

<%= if download_filename(@asciicast) do %>
  <%= render "_download_modal.html", conn: @conn, asciicast: @asciicast %>
<% end %>


adding clock

adding clock

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

    <%= label f, :name, class: "control-label" %>
    <%= text_input f, :name, class: "form-control" %>
    <%= error_tag f, :name %>

    <%= label f, :start_date, class: "control-label" %>
    <%= datetime_select f, :start_date, class: "form-control" %>
    <%= error_tag f, :start_date %>

    <%= label f, :end_date, class: "control-label" %>
    <%= datetime_select f, :end_date, class: "form-control" %>
    <%= error_tag f, :end_date %>

    <%= submit "Submit", class: "btn btn-primary" %>

    Current Time (UTC)

<% end %>

<%= form_for @changeset, @action, fn f -> %>
  <%= if @changeset.action do %>

Oops, something went wrong! Please check the errors below.

  <% end %>

    <%= label f, :name, class: "control-label" %>
    <%= text_input f, :name, class: "form-control" %>
    <%= error_tag f, :name %>

    <%= label f, :start_date, class: "control-label" %>
    <%= datetime_select f, :start_date, class: "form-control" %>
    <%= error_tag f, :start_date %>

    <%= label f, :end_date, class: "control-label" %>
    <%= datetime_select f, :end_date, class: "form-control" %>
    <%= error_tag f, :end_date %>

    <%= submit "Submit", class: "btn btn-primary" %>

<% end %>