  The response of amorphous materials to an applied strain can be continuous,
or instead display a macroscopic stress drop when a shear band nucleates. Such
discontinuous response can be observed if the initial configuration is very
stable. We study theoretically how such brittleness emerges in athermal,
quasi-statically driven, materials as their initial stability is increased. We
show that this emergence is well reproduced by elasto-plastic models and is
predicted by a mean field approximation, where it corresponds to a continuous
transition. In mean field, failure can be forecasted from the avalanche
statistics. We show that this is not the case for very brittle materials in
finite dimensions due to rare weak regions where a shear band nucleates. Their
critical radius is predicted to follow $a_c\sim (\Sigma-\Sigma_b)^{-2}$, where
$\Sigma$ is the stress and $\Sigma_b$ the stress a shear band can carry.
