Commit graph

84 commits

Author SHA1 Message Date
Stefan Mesken
019c0a0d2c
(de)-serialize a matrix (#589)
* (de)-serialize a matrix

* enable serde-serialize for nalgebra

* fix typo

* add references
2020-06-13 14:18:33 -07:00
Andrew Gauger
203b108521
test fixes (#600)
* test fixes

* filter mac osx until stable pulls right crate
2020-06-07 11:40:48 -07:00
Andrew Gauger
dd4efa8dcd
Async reqwest (#597)
* update reqwest and tokio

* Make extract link working with new packages

* Make uniq working with new packages

* Update get.md

* Make rest-post working with new packages

* Make API resource exists working with new packages

* Make Query the GitHub API working with new packages

* Fix typos

* update to edition 2018

* Extending reqwest

* fix mime request

* fix post file

* Fix download basic

* Remove toml lines

* add error handling

* Fix partial

* Improve coding in unique

* Borken links fix

* Fix retain example

* merging master

* Completed updating for async

* https://docs.rs/reqwest/0.10.6/reqwest/ references clients and they provided 404 errors

* replace anyhow with error-chain

* spelling and links

Co-authored-by: pollosp <pollo.es.pollo@gmail.com>
Co-authored-by: Olopez <pollosp@users.noreply.github.com>
2020-06-06 19:12:09 -07:00
Ivan Tham
b61c8e588a
Update to edition 2018 (#565)
* Update to edition 2018

Update mdbook to 0.3.5

Command:
sed -i '/extern crate/ {N;s/\n$//}' src/**.md; sed -i 's/extern crate error_chain;/use error_chain::error_chain;/; s/extern crate lazy_static;/use lazy_static::lazy_static;/; s/extern crate bitflags;/use bitflags::bitflags;/; s/extern crate serde_json;/ use serde_json::json;/; s/extern crate serde_derive;/use serde::{Serialize, Deserialize};/; /macro_use/d; /extern crate/ d; s/```rust/```rust,edition2018/; s/bail!/error_chain::&/; s/\(debug\|info\|warn\|error\)!/log::&/;' src/**.md

Fix #530

* Update rand-dist.md

* Fixes #569

* dump syslog

version 4 depends on error-chain v 0.11 and version 5 depends on v 0.12 
!!!!

Co-authored-by: Andrew Gauger <andygauge@gmail.com>
2020-05-31 17:26:32 -07:00
Gabriel Ghiuzan
7cce00a2c3
Fixes #570 - Updated Postgres examples (#579)
* Fixes #570 - Updated Postgres examples

* Updated postgres crate to 0.17.2

Co-authored-by: Andrew Gauger <andygauge@gmail.com>
2020-04-18 15:54:01 -07:00
Tianyi Shi
2eee704398
update rand-dist (#581)
* update rand-dist

* updates rand but still fails

* Update rand-dist.md

Co-authored-by: Andrew Gauger <andygauge@gmail.com>
2020-04-18 08:27:52 -07:00
Youngsuk Kim
579572e030
bump up 'rusqlite' to fix failing test (#582)
Fixes failing test code in 'database/sqlite/insert_select.md'
2020-04-11 13:59:12 -07:00
Josiah R
05b2fcbdc7
Fix issue #573 - hmac example (#574)
* Update hmac example for ring v. ^0.16.9

* Update hmac example for ring v. ^0.16.9

* Update hmac example for ring v. ^0.16.9

* Update to ring 0.16.11 in Cargo.toml

* Update to SHA256 - sect. 4.1 explicit threads

* Update all to SHA256, including comments
2020-02-29 21:12:36 -08:00
Jeff Hajewski
084f51cff9 Adds simple single producer, single consumer crossbeam channel example. (#551) 2019-12-16 18:22:36 -08:00
Dan Wilhelm
d7c291151f Update to ndarray 0.13 (#560) 2019-12-16 18:13:33 -08:00
Andrew Gauger
ad5f968c89
postgres version doesn't conflict with rand (#550) 2019-09-19 15:45:49 -07:00
Andrew Gauger
f4d63dada2 Merge branch 'master' of github.com:rust-lang-nursery/rust-cookbook 2019-09-19 12:52:40 -07:00
Andrew Gauger
638246385a Removing references to rand < .5 2019-09-19 12:52:27 -07:00
Jubilee
16a043b09a Update inclusive range syntax, fix script pathname, crate deps (#547)
Fix docs directing developer to incorrect pathname for spellcheck.sh
Add note on the normal behavior of spellcheck.sh for clarity
Fix instances of inclusive range syntax to use '..=' style
Depend directly on percent-encoding instead of expecting re-exports
This commit compiles and tests correctly on rustc v1.37.0

link-checker found 452 failures before this commit
link-checker found 452 failures after this commit
no new errors were added by this commit
2019-09-19 11:04:37 -07:00
Jonas Galvez
f1ad9ad44c add unicode-segmentation example (#517)
Thanks!
2019-04-12 09:05:36 -07:00
Stefan Mesken
539183c86b added invert-matrix to /science/mathematics/linear_algebra (#508)
* added invert-matrix to /science/mathematics/linear_algebra

* added nalgebra as dependency

* added nalgebra to dictionary

* fixed link to nalgebra

* Remove statistics file only includes the header
2019-04-12 08:17:46 -07:00
Brett Lyons
e2a58821c3 Updates for rand 0.6.4 (#511)
* Updated to use Uniform instead of non-extant Range

* SliceRandom replaces depcrated Rng.choose

* Updated Cargo.tml rand version "0.6"
2019-01-25 16:06:23 -08:00
Autoclave
490e97363c Fix SQLite example so it compiles (#512)
* Fix SQLite example so it compiles

* Bump rusqlite version
2019-01-25 16:04:39 -08:00
Stjepan Glavina
c1d3f12ef4 Update crossbeam-spawn.md (#496)
* Update crossbeam-spawn.md

In the latest version od Crossbeam ([docs](https://docs.rs/crossbeam/0.5.0/crossbeam/)) we have two changes:

1. Spawned closures take an argument of type `&Scope` which can be used for nested spawns.
2. The `scope` function returns a `Result` indicating whether spawned threads have been joined with success or not.

Updating the example accordingly.

* Return option from find_max

* Use split_at
2018-12-07 18:51:26 -08:00
Vishal Sodani
029b24503b Add recipe to show insert and select query for sqlite database (#455) (#491) 2018-12-07 06:29:24 -08:00
Vishal Sodani
720e65780e Add Postgres database recipe (#456) (#481)
Postgres Database Recipes
2018-10-11 13:54:46 -07:00
Laurențiu Nicola
bbc81c48d7 Bump crossbeam, image and memmap (#467) (#467) 2018-10-05 16:58:59 -07:00
Laurențiu Nicola
78a99d0eb1 Add SQLite database open recipe (#464) (#464)
Databases yay!
2018-10-05 16:54:57 -07:00
Andy Gauge
656e486ff6 cleanup 2018-10-03 15:32:21 -07:00
Laurențiu Nicola
2b29e72423 Upgrade to reqwest 0.9 (#460) 2018-10-02 15:14:37 -07:00
Siddharth Naithani
d4e44638ee added ansi_term example (#457)
* added ansi_term example

* added ansi and ansiterm to dictionary

* Delete ansi_terminal.md

* Update arguments.md

* link shows but does not work

* bug fix [link now shows and works perfectly]

* highlighted `` ansi-term name

* resolved flaws

* fixed issues with travis CI
2018-10-02 15:07:35 -07:00
Michał Budzyński
254ee9bf43 Hide examples showing custom header setup until a clean solution is available (#430)
Hidden ./src/web/clients/requests/header.md and
./src/web/clients/api/rate-limited.md as the custom header story is being reworked
in https://github.com/hyperium/headers
2018-07-11 13:13:51 -07:00
Michal Budzynski
ab7bedc0a5 bump num to 0.2 2018-07-11 10:59:21 +02:00
Andrew Gauger
97dabe59ae
Restructure Cookbook (#404) 2018-07-10 14:07:24 -07:00
Michał Budzyński
601873ec69 bump error-chain to 0.12 in order to silence unused_doc_comment (#428) 2018-07-10 13:43:57 -07:00
Yogesh Choudhary
af25e615d2 fix rand crate example and broken links 2018-06-04 12:58:13 +02:00
Michal Budzynski
6fec9ecfc4 Bump version of logging crates and fix broken links in logging.md 2018-05-15 00:44:18 +02:00
Michal Budzynski
d7c86d0560 bumped crate versions
`csv`, `hyper`, `regex`, `rayon`, `image`
2018-05-15 00:44:18 +02:00
NiekGr
24602267ea Add example "Parse the MIME type of a HTTP response" (#407)
In this example is shown how the media type of a response, received with
reqwest, can be obtained from it's headers. The media type is then
matched with predefined constants from the mime crate.
2018-05-02 16:46:38 -07:00
Michal Budzynski
333c8a2bfa Bump dependencies and fix buildbreaks 2018-01-11 15:14:43 +01:00
Michal Budzynski
38d59c3e92 [Upkeep] updated deps fixed build-breaks and sorted links 2017-11-03 03:23:28 +01:00
Michal Budzynski
85778f8586 Bumped to reqwest 0.8 and image 0.16.
Fixed resulting build breaks.
2017-10-04 10:32:36 +02:00
Michael Liu
27888c0539 Added "parse and increment a version string" example 2017-09-30 15:37:06 +02:00
Michal Budzynski
dcf288ae4e added missing cc-rs dependency to Cargo.toml 2017-09-30 02:43:20 +02:00
Michal Budzynski
c3a5a7da89 Updated to latest deps and fixed bitflags example buildbreak 2017-09-24 10:17:38 +02:00
Michal Budzynski
3fe5e09902 bumped dependencies 2017-09-09 03:41:02 +02:00
Alisha
f54723f4dd Avoid reading and writing to same file 2017-09-01 13:40:31 +02:00
Michal Budzynski
d059872395 Bumped syslog to 3.3.0 and fixed buildbreak 2017-08-21 09:25:45 +02:00
Michal Budzynski
b31ac80161 Updated cookbook dependencies and reqwest examples build with 0.7 API 2017-08-15 22:57:41 +02:00
Michal Budzynski
fcb097e72c move to skeptic 0.12.1 2017-07-31 17:45:18 +02:00
Ted Mielczarek
29184f9e43 Add an example of calculating the SHA-256 digest of a file using ring 2017-07-29 22:28:33 +02:00
Alisha
1515289a1d Serialize records to CSV 2017-07-23 18:38:14 +05:30
Michal Budzynski
c2876df252 Updated skeptic to "0.11.0" and added missing dependencies
- updated to skeptic "0.11.0" finally fixing buildbreaks on duplicated deps
- added missing `log` and `base64` deps
- sorted dependencies in Cargo.toml
2017-07-13 13:28:47 +02:00
Michal Budzynski
a0fe9d180a Added minimal "Operate on bitflags" example
also updated dependencies to avoid skeptic test buildbreak
2017-07-11 16:13:58 +02:00
Portal-Chan
4ce1109c06 Add examples for the glob crate 2017-07-06 21:53:14 +02:00