For many years a combined analysis of pionic hydrogen and deuterium atoms has been known as a good tool to extract information on the isovector and especially on the isoscalar s-wave πN scattering length. However, given the smallness of the isoscalar scattering length, the analysis becomes useful only if the pion-deuteron scattering length is controlled theoretically to a high accuracy comparable to the experimental precision. To achieve the required few-percent accuracy one needs theoretical control over all isospin-conserving three-body πNN → πNN operators up to one order before the contribution of the dominant unknown (N † N) 2 ππ contact term. This term appears at next-to-next-to-leading order in Weinberg counting. In addition, one needs to include isospin-violating effects in both two-body (πN) and three-body (πNN) operators. In this talk we discuss the results of the recent analysis where these isospin-conserving and -violating effects have been carefully taken into account. Based on this analysis, we present the up-to-date values of the s-wave πN scattering lengths.