Retrieve Content from and Interact with 'Gopher' Servers
The 'Gopher' protocol is a 'TCP/IP' application layer protocol designed for distributing, searching, and retrieving documents over the Internet. The 'Gopher' protocol was strongly oriented towards a menu-document design and presented an alternative to the World Wide Web in its early stages, but ultimately 'Hypertext Transfer Protocol' ('HTTP') became the dominant protocol. The 'Gopher' ecosystem is often regarded as the effective predecessor of the 'World Wide Web'. Tools are provided to interact with and retrieve content from 'Gopher' servers.
The following functions are implemented:
gopher
: Fetch a resource using the gopher protocolg_content
: Retrieve the content portion of a gopher responseurl
parameter to gopher()
URL
selectorsdevtools::install_github("hrbrmstr/varmint")
options(width=120)
library(varmint) library(tidyverse) # current verison packageVersion("varmint")
x <- gopher("gopher.floodgap.com")
str(x)
x
g_content(x, TRUE) %>% print(n = 20)
x1 <- gopher("gopher://gopher.floodgap.com", "/new")
x1
g_content(x1, TRUE) %>% print(n = 20)
x2 <- gopher("gopher://gopher.floodgap.com", "/v2")
x2
g_content(x2, TRUE) %>% print(n = 20)
x3 <- gopher("gopher://gopher.floodgap.com", "/v2/vs", "xkcd")
x3
g_content(x3, TRUE) %>% filter(item_type_descr == "info")
g_content(x3, TRUE) %>% filter(item_type_descr == "menu")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.